You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This guide walks you through integrating Novu’s Inbox into your Angular application for real time in-app notifications, from setup to triggering your first notification. By the end, you'll have a working notification inbox.
15
17
@@ -20,27 +22,24 @@ This guide walks you through integrating Novu’s Inbox into your Angular applic
20
22
<Steps>
21
23
<Step>
22
24
### Create a Novu account
23
-
[Create a Novu account](https://dashboard-v2.novu.co/auth/sign-up)or [sign in](https://dashboard-v2.novu.co/auth/sign-in)to an existing account.
25
+
<ahref="https://dashboard.novu.co/auth/sign-up"target="_blank"rel="noopener noreferrer">Create a Novu account</a> or <ahref="https://dashboard.novu.co/auth/sign-in"target="_blank"rel="noopener noreferrer">sign in</a> to access the Novu dashboard.
24
26
</Step>
25
27
26
28
<Step>
27
-
### Create an Angular application
28
-
Create a new Angular app with [angular cli](https://angular.dev/tools/cli) using the command below. Skip this step if you already have an existing project:
29
+
### Create an Angular application
30
+
Run the following command to create a new Angular app using <ahref="https://angular.dev/tools/cli/setup-local#install-the-angular-cli"target="_blank"rel="noopener noreferrer">angular cli</a>:
29
31
30
32
```bash
31
33
ng new novu-inbox-angular
32
-
```
33
-
34
-
Navigate to the newly created project:
35
-
36
-
```bash
37
34
cd novu-inbox-angular
38
35
```
39
36
</Step>
40
37
41
38
<Step>
42
-
### Install the required package
43
-
Run the command below to install [Novu Javascript SDK](/platform/sdks/javascript), which provides required component for Inbox UI:
39
+
### Install `@novu/js`
40
+
The [Novu JavaScript SDK](/platform/sdks/javascript) gives you access to the Inbox component.
41
+
42
+
Run the following command to install the SDK:
44
43
45
44
```package-install
46
45
npm install @novu/js
@@ -50,45 +49,11 @@ This guide walks you through integrating Novu’s Inbox into your Angular applic
50
49
51
50
<Step>
52
51
### Add the Inbox component
53
-
Update the `src/app/app.component.ts` file to add the Inbox component passing :tooltip[applicationIdentifier]{label="The application identifier is a unique identifier for your application. You can find it in the Novu Dashboard under the API keys page."} and :tooltip[subscriberId]{label="The subscriber ID is the unique identifier for the user in your application, typically the user's id in your database."}:
[Sign in](https://dashboard-v2.novu.co/auth/sign-up) to get your own API keys
89
-
</div>
90
-
91
-
If you’re signed in to your Novu account, then the :tooltip[applicationIdentifier]{label="The application identifier is a unique identifier for your application. You can find it in the Novu Dashboard under the API keys page."} and :tooltip[subscriberId]{label="The subscriber ID is the unique identifier for the user in your application, typically the user's id in your database."} are automatically entered in the code sample above. Otherwise, you can manually retrieve them:
52
+
Update the `src/app/app.ts` file to add the Inbox component. You'll need to provide your :tooltip[applicationIdentifier]{label="The application identifier is a unique identifier for your application. You can find it in the Novu Dashboard under the API keys page."} and :tooltip[subscriberId]{label="The subscriber ID is the unique identifier for the user in your application, typically the user's id in your database."}:
53
+
54
+
<CodeTemplateBlocktemplateId="angular-inbox" />
55
+
56
+
If you’re signed in to your Novu account, then the :tooltip[applicationIdentifier]{label="The application identifier is a unique identifier for your application. You can find it in the Novu Dashboard under the API keys page."} and :tooltip[subscriberId]{label="The subscriber ID is the unique identifier for the user in your application, typically the user's id in your database."} are automatically entered in the code sample above. Otherwise, you can manually retrieve them:
92
57
* `applicationIdentifier` - In the Novu dashboard, click API Keys, and then locate your unique Application Identifier.
93
58
* `subscriberId` - This represents a user in your system (typically the user's ID in your database). For quick start purposes, an auto-generated subscriberId is provided for your Dashboard user.
94
59
@@ -100,20 +65,22 @@ export class AppComponent implements AfterViewInit {
100
65
101
66
<Step>
102
67
### Add the Inbox component to your application
103
-
Add a `#novuInbox` reference to your application in the starting of the `src/app/app.component.html` file:
68
+
Add a `#novuInbox` reference to your application in the starting of the `src/app/app.html` file:
104
69
105
-
```html title="src/app/app.component.html"
70
+
```html title="src/app/app.html"
106
71
<div#novuInbox></div>
107
72
```
108
73
</Step>
109
74
110
75
<Step>
76
+
111
77
### Run Your Application
112
78
Start your development server:
113
79
114
80
```package-install
115
81
npm run start
116
82
```
83
+
117
84
Once the application is running, a bell icon will appear on the top left side of the screen. Clicking it opens the notification inbox UI.
118
85
119
86
Currently, there are no notifications. Let’s trigger one!
Copy file name to clipboardExpand all lines: content/docs/platform/quickstart/nextjs.mdx
+11-2Lines changed: 11 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,12 +29,21 @@ Learn how to integrate Novu’s Inbox for real-time in-app notifications in your
29
29
<Steps>
30
30
<Step>
31
31
### Create a Novu account
32
-
[Create a Novu account](https://dashboard.novu.co/auth/sign-up)or [sign in](https://dashboard.novu.co/auth/sign-in) to access the Novu dashboard.
32
+
<ahref="https://dashboard.novu.co/auth/sign-up"target="_blank"rel="noopener noreferrer">Create a Novu account</a> or <ahref="https://dashboard.novu.co/auth/sign-in"target="_blank"rel="noopener noreferrer">sign in</a> to access the Novu dashboard.
33
33
</Step>
34
34
35
+
<Step>
36
+
### Create a new Next.js application
37
+
Run the following command to <ahref="https://nextjs.org/docs/app/getting-started/installation"target="_blank">create a new Next.js application</a>:
38
+
39
+
```package-install
40
+
npm create next-app@latest
41
+
```
42
+
</Step>
43
+
35
44
<Step>
36
45
### Install `@novu/nextjs`
37
-
In your Next.js project, run the following command to install the Novu Inbox SDK:
46
+
Run the following command to install the Next.js Novu SDK:
This guide walks you through integrating Novu’s Inbox into your React application for in-app notifications in real-time, from setup to triggering your first notification. By the end, you'll have a working notification inbox.
26
27
27
28
<Steps>
28
29
<Step>
29
30
### Create a Novu account
30
-
[Create a Novu account](https://dashboard.novu.co/auth/sign-up)or [sign in](https://dashboard.novu.co/auth/sign-in)to an existing account.
31
+
<ahref="https://dashboard.novu.co/auth/sign-up"target="_blank"rel="noopener noreferrer">Create a Novu account</a> or <ahref="https://dashboard.novu.co/auth/sign-in"target="_blank"rel="noopener noreferrer">sign in</a> to access the Novu dashboard.
31
32
</Step>
32
33
33
34
<Step>
34
-
### Create a React application
35
-
Create a new React app with[Vite](https://vite.dev/guide/#scaffolding-your-first-vite-project) using the command below. Skip this step if you already have an existing project:
35
+
### Create a React app using Vite
36
+
Run the following command to create a new React app using[Vite](https://vite.dev/guide/#scaffolding-your-first-vite-project):
Run the command below to install [Novu React SDK](/platform/sdks/react), which provides React components for building notification UIs and React Router Dom:
48
+
### Install `@novu/react`
49
+
The [Novu React SDK](/platform/sdks/react) gives you access to the Inbox component.
50
+
51
+
Run the following command to install the SDK and React Router Dom:
46
52
47
53
```package-install
48
54
npm install @novu/react react-router-dom
@@ -54,29 +60,9 @@ This guide walks you through integrating Novu’s Inbox into your React applicat
54
60
### Create the Inbox component
55
61
In the `src` directory, create a `components/notification-center.tsx` file and use the <Methodhref="/platform/inbox/react/components/inbox">{`<Inbox />`}</Method> component, passing :tooltip[applicationIdentifier]{label="The application identifier is a unique identifier for your application. You can find it in the Novu Dashboard under the API keys page."} and :tooltip[subscriberId]{label="The subscriber ID is the unique identifier for the user in your application, typically the user's id in your database."}:
[Sign in](https://dashboard.novu.co/auth/sign-up) to get your own API keys
77
-
</div>
63
+
<CodeTemplateBlocktemplateId="react-inbox" />
78
64
79
-
If you’re signed in to your Novu account, then the :tooltip[applicationIdentifier]{label="The application identifier is a unique identifier for your application. You can find it in the Novu Dashboard under the API keys page."} and :tooltip[subscriberId]{label="The subscriber ID is the unique identifier for the user in your application, typically the user's id in your database."} are automatically entered in the code sample above. Otherwise, you can manually retrieve them:
65
+
If you’re signed in to your Novu account, then the :tooltip[applicationIdentifier]{label="The application identifier is a unique identifier for your application. You can find it in the Novu Dashboard under the API keys page."} and :tooltip[subscriberId]{label="The subscriber ID is the unique identifier for the user in your application, typically the user's id in your database."} are automatically entered in the code sample above. Otherwise, you can manually retrieve them:
80
66
* `applicationIdentifier` – In the Novu dashboard, click API Keys, and then locate your unique Application Identifier.
81
67
* `subscriberId` – This represents a user in your system (typically the user's ID in your database). For quick start purposes, an auto-generated subscriberId is provided for your Dashboard user.
This guide walks you through integrating Novu’s Inbox into your Remix application for in-app notifications in real-time, from setup to triggering your first notification. By the end, you'll have a working notification inbox.
26
27
27
28
<Steps>
28
29
<Step>
29
30
### Create a Novu account
30
-
[Create a Novu account](https://dashboard.novu.co/auth/sign-up)or [sign in](https://dashboard.novu.co/auth/sign-in)to an existing account
31
+
<ahref="https://dashboard.novu.co/auth/sign-up"target="_blank"rel="noopener noreferrer">Create a Novu account</a> or <ahref="https://dashboard.novu.co/auth/sign-in"target="_blank"rel="noopener noreferrer">sign in</a> to access the Novu dashboard.
31
32
</Step>
32
33
33
34
<Step>
34
35
### Create a Remix application
35
-
Create a new Remix app using the command below. Skip this step if you already have an existing project:
36
+
Run the following command to create a new Remix app:
36
37
37
38
```package-install
38
39
npx create-remix@latest
@@ -41,7 +42,11 @@ This guide walks you through integrating Novu’s Inbox into your Remix applicat
41
42
</Step>
42
43
43
44
<Step>
44
-
### Install Novu’s inbox package
45
+
### Install `@novu/react`
46
+
The [Novu React SDK](/platform/sdks/react) gives you access to the Inbox component.
47
+
48
+
Run the following command to install the SDK:
49
+
45
50
```package-install
46
51
npm install @novu/react
47
52
```
@@ -51,27 +56,7 @@ This guide walks you through integrating Novu’s Inbox into your Remix applicat
51
56
### Create an Inbox component
52
57
In the `app` directory, create a `components/notification-center.tsx` file and use the <Methodhref="/platform/inbox/react/components/inbox">{`<Inbox />`}</Method> component, passing :tooltip[applicationIdentifier]{label="The application identifier is a unique identifier for your application. You can find it in the Novu Dashboard under the API keys page."} and :tooltip[subscriberId]{label="The subscriber ID is the unique identifier for the user in your application, typically the user's id in your database."}:
[Sign in](https://dashboard.novu.co/auth/sign-up) to get your own API keys
74
-
</div>
59
+
<CodeTemplateBlocktemplateId="remix-inbox" />
75
60
76
61
If you’re signed in to your Novu account, then the :tooltip[applicationIdentifier]{label="The application identifier is a unique identifier for your application. You can find it in the Novu Dashboard under the API keys page."} and :tooltip[subscriberId]{label="The subscriber ID is the unique identifier for the user in your application, typically the user's id in your database."} are automatically entered in the code sample above. Otherwise, you can manually retrieve them:
77
62
* `applicationIdentifier` – In the Novu dashboard, click API Keys, and then locate your unique Application Identifier.
0 commit comments