Enterprise Notification Center with security update, server maintenance, new policy alerts, and quick access buttons

Technical Blog Article — App 51: Enterprise Notification Center with React, TypeScript, Fluent UI, and Vite

Introduction

Modern enterprise systems are heavily driven by notifications. Every corporate platform needs a way to communicate information to users:

  • system alerts
  • workflow approvals
  • deployment updates
  • security warnings
  • ticket updates
  • SharePoint events
  • Microsoft Teams activities
  • audit messages
  • business alerts
  • operational status

This is why notification systems are one of the most important UI patterns in enterprise frontend engineering.

In App 51 — Notification Center, we build a Microsoft-style enterprise notification system using:

  • React
  • TypeScript
  • Vite
  • Fluent UI

This application belongs to Block 3 — Professional Fluent UI Applications, where the focus evolves from basic React rendering into enterprise UI architecture and Microsoft design patterns.

The goal of this app is not just visual styling. The real objective is understanding how React transforms structured data into reusable enterprise interfaces.

This app introduces:

  • data-driven rendering
  • reusable card systems
  • notification modeling
  • conditional rendering
  • Fluent UI enterprise components
  • visual hierarchy
  • Microsoft design system principles
  • enterprise composition patterns

The React mental model reinforced here is:

Structured data
→ component rendering
→ enterprise UI

This is one of the most important ideas in React architecture.


Why Notification Systems Matter

Notification systems appear everywhere in modern enterprise software.

Examples:

  • Microsoft 365
  • SharePoint Online
  • Teams
  • Azure Portal
  • Admin Centers
  • CRM platforms
  • ERP systems
  • monitoring dashboards
  • DevOps systems
  • analytics platforms

A notification center is essentially:

  • a structured collection of messages
  • rendered dynamically
  • visually categorized
  • prioritized
  • reusable

This makes notification systems perfect for learning React composition.


What This App Teaches

ConceptExplanation
Data-driven renderingUI generated from data
Reusable componentsNotification cards reused multiple times
TypeScript modelsStrongly typed enterprise data
Conditional renderingDifferent visuals for different notification types
Fluent UIMicrosoft enterprise UI components
Declarative UIReact derives UI from data
Component compositionApp → List → Card hierarchy
List renderingmap() converts arrays into UI

1. Creating the Project

The project begins using Vite with React TypeScript.

Vite is one of the fastest modern frontend build tools and development servers available today.

Project creation:

mkdir bloco03
cd bloco03
npm create vite@latest app51-notification-center -- --template react-ts
cd app51-notification-center
npm install
npm install @fluentui/react-components @fluentui/react-icons

Why Vite Matters

Vite improves development speed significantly because it:

  • uses native ES Modules
  • provides instant startup
  • supports Hot Module Replacement
  • compiles TypeScript efficiently
  • handles React JSX automatically

Official documentation:


2. Creating the Folder Structure

Professional React applications should always separate responsibilities.

Create folders:

New-Item src\components -ItemType Directory
New-Item src\models -ItemType Directory
New-Item src\data -ItemType Directory
New-Item src\styles -ItemType Directory

Create files:

New-Item src\models\NotificationItem.ts -ItemType File
New-Item src\data\notifications.ts -ItemType File
New-Item src\components\NotificationCard.tsx -ItemType File
New-Item src\components\NotificationList.tsx -ItemType File
New-Item artigo.md -ItemType File

Final Project Structure

app51-notification-center/
src/
components/
NotificationCard.tsx
NotificationList.tsx
data/
notifications.ts
models/
NotificationItem.ts
styles/
App.tsx
main.tsx
index.css

Each file has one responsibility.

FileResponsibility
NotificationItem.tsDefines the notification structure
notifications.tsProvides notification data
NotificationCard.tsxRenders one notification
NotificationList.tsxRenders all notifications
App.tsxMain enterprise layout
main.tsxReact entry point
index.cssGlobal CSS

This separation becomes critical in enterprise React architecture.


3. Understanding the Notification Model

src\models\NotificationItem.ts

export type NotificationType =
| "success"
| "warning"
| "error"
| "info";
export interface NotificationItem {
id: number;
title: string;
message: string;
type: NotificationType;
createdAt: string;
read: boolean;
}

This file defines the shape of a notification.

The model guarantees every notification has:

  • unique identifier
  • title
  • message
  • type
  • creation timestamp
  • read/unread status

This is extremely important in TypeScript.

Without models:

  • data becomes unpredictable
  • rendering becomes unsafe
  • refactoring becomes difficult

Enterprise React applications should always use typed models.


Why NotificationType Matters

This construction:

type NotificationType =
| "success"
| "warning"
| "error"
| "info";

creates a restricted union type.

This means the notification type can ONLY be:

  • success
  • warning
  • error
  • info

If you accidentally write:

type: "banana"

TypeScript immediately shows an error.

This is one of the biggest advantages of TypeScript in enterprise systems.

Official documentation:


4. Understanding the Data Layer

src\data\notifications.ts

This file stores static enterprise notification data.

export const notifications: NotificationItem[] = [...]

The important part is:

NotificationItem[]

This means:

  • the variable is an array
  • every item must follow the NotificationItem structure

This guarantees consistency across the application.


Why Static Data First?

This app intentionally uses static data because the focus is:

  • rendering
  • composition
  • UI architecture

NOT:

  • APIs
  • async behavior
  • useEffect
  • backend integration

The React Learn philosophy encourages mastering rendering first before introducing external systems.

Official React documentation:


5. Understanding the Notification Card

src\components\NotificationCard.tsx

This component renders one notification.

This is the heart of reusable React architecture.

The component receives props:

interface NotificationCardProps {
notification: NotificationItem;
}

This means:

  • the card is reusable
  • the card does not own data
  • the parent passes the notification

This is component composition.


Understanding React Props

Props are inputs for components.

Conceptually:

Parent component
→ sends data through props
→ child component renders UI

This is one of React’s most important ideas.

Official documentation:


6. Understanding Conditional Rendering

The app uses helper functions:

function getNotificationIcon(type)

and:

function getBadgeAppearance(type)

These functions change the UI depending on notification type.

Example:

success → success icon
warning → warning icon
error → error icon
info → info icon

This is conditional rendering.

React allows the interface to adapt dynamically based on data.

Official documentation:


7. Understanding Fluent UI

The app uses:

  • Card
  • Badge
  • Text
  • Typography
  • Fluent icons

Fluent UI provides:

  • Microsoft design consistency
  • accessibility
  • keyboard navigation
  • spacing system
  • typography system
  • enterprise layout behavior

Official documentation:


Why Card Matters

The Card component acts as the notification container.

It automatically provides:

  • spacing
  • border behavior
  • visual hierarchy
  • enterprise styling

Without Fluent UI, all this would require manual CSS.


Why Badge Matters

The Badge visually categorizes the notification.

Example:

  • SUCCESS
  • WARNING
  • ERROR
  • INFO

Enterprise applications rely heavily on visual categorization because users need to identify information quickly.


8. Understanding NotificationList.tsx

This component renders the collection of notifications.

The key section is:

notifications.map((notification) => (
<NotificationCard
key={notification.id}
notification={notification}
/>
))

This is one of the most important React patterns.


Why map() Is Critical in React

map() transforms data into UI.

Conceptually:

notification 1 → NotificationCard 1
notification 2 → NotificationCard 2
notification 3 → NotificationCard 3

React applications are fundamentally:

  • data
  • transformed into UI

Official documentation:


Why key={notification.id} Matters

React requires stable keys for list rendering.

The key helps React:

  • identify items
  • optimize rendering
  • update the correct DOM nodes

Without keys:

  • React shows warnings
  • rendering becomes less predictable

The key should always be:

  • unique
  • stable

9. Understanding the Root App

src\App.tsx

This file defines the enterprise layout.

The structure is:

App
NotificationList
NotificationCard

The root layout creates:

  • centered container
  • enterprise spacing
  • dashboard-style composition

Why the Layout Uses maxWidth

maxWidth: "900px"

This prevents the notification center from stretching infinitely on large monitors.

Enterprise layouts usually use:

  • content width constraints
  • spacing systems
  • readable line lengths

This improves UX significantly.


10. Understanding main.tsx

The file:

src/main.tsx

connects React to the browser.

Important section:

<FluentProvider theme={webLightTheme}>

This activates:

  • Microsoft theme
  • Fluent typography
  • design tokens
  • enterprise styling

Without FluentProvider, Fluent UI components lose their visual system.


11. Why There Is No useState

This app intentionally does NOT use:

  • useState
  • useEffect

Why?

Because this app is focused on:

  • rendering
  • composition
  • visual architecture

NOT interactivity.

This follows React Learn:

  • first learn rendering
  • then learn state
  • then learn effects

Official documentation:


12. Why There Is No useEffect

There is no:

  • API
  • timer
  • external synchronization

Therefore:

  • useEffect is unnecessary

This is extremely important.

React Learn strongly recommends avoiding unnecessary effects.

Official documentation:


13. Complete Rendering Flow

main.tsx
renders App
App
renders NotificationList
NotificationList
loops through notification data
NotificationCard
renders each enterprise notification

This is declarative rendering.


14. Enterprise UI Mental Model

The notification system reinforces the React mental model:

Data
→ Components
→ UI

NOT:

manually create DOM elements
manually update HTML
manually manipulate UI

React handles DOM synchronization automatically.


15. Technical Summary

ConceptExplanation
TypeScript ModelDefines notification structure
Notification DataEnterprise notification dataset
Reusable CardNotification UI component
map() RenderingConverts data into UI
Fluent UI CardMicrosoft notification container
Fluent UI BadgeVisual notification categorization
Conditional RenderingDynamic icons and styles
CompositionApp → List → Card
Declarative UIUI derived from data
FluentProviderGlobal Microsoft theme

16. Concept Table

ConceptFilePurpose
Notification modelNotificationItem.tsStrong typing
Notification datasetnotifications.tsStatic enterprise data
Reusable componentNotificationCard.tsxNotification rendering
List renderingNotificationList.tsxDynamic UI generation
Root layoutApp.tsxEnterprise shell
React entry pointmain.tsxBrowser mounting
Global CSSindex.cssLayout reset

17. Official Documentation

React

Fluent UI

Vite

TypeScript


18. Final Architectural Insight

This application may look visually simple, but architecturally it introduces one of the most important frontend patterns in enterprise systems:

Structured enterprise data
→ reusable components
→ scalable UI architecture

This same pattern will later evolve into:

  • live notifications
  • API-driven dashboards
  • Teams-like activity feeds
  • SharePoint alert systems
  • monitoring systems
  • audit centers
  • enterprise admin portals

Mastering this pattern is critical because large React applications are fundamentally:

  • data
  • rendered through reusable components
  • composed into scalable UI systems

Current Project Progress

BlockAppNameStatus
Block 101Hello React FluentCompleted
Block 102Profile CardCompleted
Block 103Product ListCompleted
Block 104Microsoft Style User CardCompleted
Block 105Static DashboardCompleted
Block 106Corporate Sidebar MenuCompleted
Block 107Visual Task ListCompleted
Block 108Timeline EventsCompleted
Block 109Employee TableCompleted
Block 110Email ListCompleted
Block 111Grid of CardsCompleted
Block 112Image GalleryCompleted
Block 113Movie CatalogCompleted
Block 114Football TeamsCompleted
Block 115News PageCompleted
Block 116Financial DashboardCompleted
Block 117SharePoint Style LayoutCompleted
Block 118File ExplorerCompleted
Block 119Corporate PortalCompleted
Block 120Microsoft Style Landing PageCompleted
Block 221Modern CounterCompleted
Block 222Toggle ThemeCompleted
Block 223React CalculatorCompleted
Block 224Login FormCompleted
Block 225User RegistrationCompleted
Block 226Complete ToDo ListCompleted
Block 227Shopping ListCompleted
Block 228Product FilterCompleted
Block 229Employee SearchCompleted
Block 230Shopping CartCompleted
Block 231Grade SimulatorCompleted
Block 232Inventory ControlCompleted
Block 233Contact AgendaCompleted
Block 234Currency ConverterCompleted
Block 235BMI CalculatorCompleted
Block 236Installment SimulatorCompleted
Block 237Voting PanelCompleted
Block 238Interactive QuizCompleted
Block 239Team ManagerCompleted
Block 240Dynamic DashboardCompleted
Block 341Microsoft Style LoginCompleted
Block 342Corporate FormCompleted
Block 343Tabs NavigationCompleted
Block 344Dialog ManagerCompleted
Block 345Executive DashboardCompleted
Block 346DataGrid CatalogCompleted
Block 347Enterprise User ListCompleted
Block 348Sidebar NavigationCompleted
Block 349Corporate HeaderCompleted
Block 350Professional ToolbarCompleted
Block 351Notification CenterCurrent
Block 352Administrative PanelNext

Edvaldo Guimrães Filho Avatar

Published by