|
| 1 | +<<<<<<< HEAD |
| 2 | + |
1 | 3 | #
|
2 | 4 |
|
3 |
| -<a alt="Nx logo" href="https://nx.dev" target="_blank" rel="noreferrer"><img src="https://raw.githubusercontent.com/nrwl/nx/master/images/nx-logo.png" width="45"></a> |
| 5 | +======= |
| 6 | + |
| 7 | +# Angular 16, Payload CMS, ExpressJs - Free Open-Source Full-Stack Boilerplate |
| 8 | + |
| 9 | +> > > > > > > a3439a7 (update README) |
4 | 10 |
|
| 11 | +**✨ Professional Web Application Development Starter without the complexity.** |
| 12 | + |
| 13 | +<<<<<<< HEAD |
5 | 14 | **[Join Discord Community](https://discord.gg/ERPCG8W6)**
|
6 | 15 |
|
7 | 16 | <div style="display: flex; flex-direction: row; justify-content: space-between;">
|
8 | 17 | <img src="https://binarystarter.com/assets/images/angular/free-architecture-nodejs.png" width="380px" style="width: '100%'; height: auto;"/>
|
9 | 18 | <img src="https://binarystarter.com/assets/images/angular/free-architecture-angular.png" width="380px" style="width: '100%'; height: auto;"/>
|
10 | 19 | </div>
|
| 20 | +======= |
| 21 | +Secure, Stable, Automated. |
| 22 | + |
| 23 | +**[Join Discord Community](https://discord.gg/ERPCG8W6)** |
| 24 | + |
| 25 | +> > > > > > > a3439a7 (update README) |
| 26 | +
|
| 27 | +<div style="display: flex; flex-direction: row; justify-content: space-between;"> |
| 28 | + <img src="https://binarystarter.com/assets/images/angular/free-architecture-nodejs.png" width="380px" style="width: '100%'; height: auto;"/> |
| 29 | + <img src="https://binarystarter.com/assets/images/angular/free-architecture-angular.png" width="380px" style="width: '100%'; height: auto;"/> |
| 30 | +</div> |
| 31 | + |
| 32 | +# Features |
| 33 | + |
| 34 | +<<<<<<< HEAD |
| 35 | + |
| 36 | +# Installation |
| 37 | + |
| 38 | +# For full documentation refer to https://binarystartercom.notion.site/Documentation-binarystarter-angular-87b451a08050465e83bb47fc124a9029?pvs=4 |
11 | 39 |
|
12 |
| -## Start the app |
| 40 | +- Payload CMS (headless open-source CMS) |
| 41 | +- I18n |
| 42 | +- TailwindCSS |
| 43 | +- Angular Material |
| 44 | +- Lazy Loading |
| 45 | +- Server Side Rendering App |
| 46 | +- Client Side App |
| 47 | +- Authentication, Authorization |
| 48 | +- Lazy loaded Dashboard for authenticated users |
| 49 | +- Standalone Components |
| 50 | +- Pnpm, esbuild |
13 | 51 |
|
14 |
| -To start the development server run `nx serve express`. Open your browser and navigate to http://localhost:4200/. Happy coding! |
| 52 | +<img src="https://binarystarter.com/assets/images/angular/dashboard-payload.png" width="420px"/> |
| 53 | +>>>>>>> a3439a7 (update README) |
15 | 54 |
|
16 | 55 | # Installation
|
17 | 56 |
|
18 | 57 | For full documentation refer to https://binarystartercom.notion.site/Documentation-binarystarter-angular-87b451a08050465e83bb47fc124a9029?pvs=4
|
19 | 58 |
|
20 |
| -If you happen to use Nx plugins, you can leverage code generators that might come with it. |
| 59 | +#### Resources |
21 | 60 |
|
22 |
| -Run `nx list` to get a list of available plugins and whether they have generators. Then run `nx list <plugin-name>` to see what generators are available. |
| 61 | +- [Intro to nx](https://nx.dev/getting-started/intro) |
| 62 | +- [Install nx](https://nx.dev/getting-started/installation) |
| 63 | +- [Why nx?](https://nx.dev/getting-started/why-nx) |
| 64 | +- [nx: Run Tasks](https://nx.dev/core-features/run-tasks) |
| 65 | +- [nx: Mental Model](https://nx.dev/concepts/mental-model) |
| 66 | +- [pnpm commands](https://github.com/nvm-sh/nvm#usage) |
23 | 67 |
|
24 |
| -Learn more about [Nx generators on the docs](https://nx.dev/plugin-features/use-code-generators). |
| 68 | +#### Prerequisites: |
25 | 69 |
|
26 |
| -## Running tasks |
| 70 | +- [Install pnpm](https://pnpm.io/installation) |
| 71 | +- [Install nx cli globally](https://nx.dev/getting-started/installation#installing-nx-globally) |
| 72 | +- Install nodejs v18 |
27 | 73 |
|
28 |
| -To execute tasks with Nx use the following syntax: |
| 74 | +Let’s get started! 🚀 |
29 | 75 |
|
30 |
| -``` |
31 |
| -nx <target> <project> <...options> |
32 |
| -``` |
| 76 | +#### Clone GitHub Repository |
33 | 77 |
|
34 |
| -You can also run multiple targets: |
| 78 | +Run in a terminal `git clone https://github.com/binarystarter/binarystarter-angular.git`. To specify another folder name, you can do a direct `git clone https://github.com/binarystarter/binarystarter-angular.git <project_name>`. |
35 | 79 |
|
36 |
| -``` |
37 |
| -nx run-many -t <target1> <target2> |
38 |
| -``` |
| 80 | +### Install modules |
39 | 81 |
|
40 |
| -..or add `-p` to filter specific projects |
| 82 | +Run `pnpm install`. |
41 | 83 |
|
42 | 84 | ### Start the app
|
43 | 85 |
|
44 | 86 | Documentation: https://binarystartercom.notion.site/Documentation-binarystarter-angular-87b451a08050465e83bb47fc124a9029?pvs=4
|
45 | 87 |
|
46 |
| -Targets can be defined in the `package.json` or `projects.json`. Learn more [in the docs](https://nx.dev/core-features/run-tasks). |
| 88 | +# The app |
| 89 | + |
| 90 | +### Angular |
| 91 | + |
| 92 | +The angular app can be accessed using http://localhost:4200 - the Server Side Rendered app |
| 93 | +The Angular client-side app can be accessed at HTTP://localhost:4200/app/... and HTTP://localhost:4200/auth/... |
| 94 | + |
| 95 | +### Payload CMS |
| 96 | + |
| 97 | +The payloadcms administration panel can be accessed at HTTP://localhost:8080/admin |
| 98 | + |
| 99 | +### ExpressJS |
| 100 | + |
| 101 | +ExpressJS endpoints can be accessed from HTTP://localhost:8080/... |
| 102 | + |
| 103 | +# Out-of-the-box |
| 104 | + |
| 105 | +## Authentication and Authorization |
| 106 | + |
| 107 | +The authentication system is based on Passport Js. |
| 108 | + |
| 109 | +Out of the box you get the following pages in Angular, connected with the ExpressJs and Payload CMS. |
| 110 | + |
| 111 | +## Angular SSR and Dashboard App |
| 112 | + |
| 113 | +Angular comes with separated modules for the static pages and the single page application. |
| 114 | + |
| 115 | +Separation of concerns is very important at this stage of development of the Angular Universal. |
| 116 | + |
| 117 | +Static Pages are encapsuled in their modules and they don’t interact with browser APIs hungry components. |
| 118 | + |
| 119 | +## DRY - Shared Types between the Backend and Frontend |
| 120 | + |
| 121 | +The Backend TypeScript types should not be available on the Frontend. |
47 | 122 |
|
48 |
| -## Want better Editor Integration? |
| 123 | +What most developers do is create the same types on both frontend and backend APIs, which makes a bad precedence of duplicated code. |
49 | 124 |
|
50 |
| -Have a look at the [Nx Console extensions](https://nx.dev/nx-console). It provides autocomplete support, a UI for exploring and running tasks & generators, and more! Available for VSCode, IntelliJ and comes with a LSP for Vim users. |
| 125 | +This problem is solved by using a mono repository. |
51 | 126 |
|
52 |
| -## Ready to deploy? |
| 127 | +Managed by nx.dev tools - now extending TypeScript types from the Backend or creating them from scratch can be done in a single shared library between your Angular app and ExpressJs Backend. |
53 | 128 |
|
54 |
| -Just run `nx build demoapp` to build the application. The build artifacts will be stored in the `dist/` directory, ready to be deployed. |
| 129 | +## ExpressJs Server integrated with Payload CMS out of the box |
55 | 130 |
|
56 |
| -## Set up CI! |
| 131 | +We get all the benefits of a monorepository out of the box. |
57 | 132 |
|
58 |
| -Nx comes with local caching already built-in (check your `nx.json`). On CI you might want to go a step further. |
| 133 | +ExpressJs is tightly integrated with PayloadCMS, but you can still add your own routes, outside of Payload. |
59 | 134 |
|
60 |
| -- [Set up remote caching](https://nx.dev/core-features/share-your-cache) |
61 |
| -- [Set up task distribution across multiple machines](https://nx.dev/nx-cloud/features/distribute-task-execution) |
62 |
| -- [Learn more how to setup CI](https://nx.dev/recipes/ci) |
| 135 | +We believe in TypeScript, hence everything is based on TypeScript. |
63 | 136 |
|
64 |
| -## Connect with us! |
| 137 | +# Connect with me |
65 | 138 |
|
66 |
| -- [Join the community](https://nx.dev/community) |
67 |
| -- [Subscribe to the Nx Youtube Channel](https://www.youtube.com/@nxdevtools) |
68 |
| -- [Follow us on Twitter](https://twitter.com/nxdevtools) |
| 139 | +- [Twitter](https://twitter.com/florinmtsc) |
| 140 | +- [Website](https://binarycentrum.com/) |
0 commit comments