├── .prettierignore
├── packages
├── yonode
│ ├── .gitignore
│ └── src
│ │ ├── lib
│ │ ├── programOptions.js
│ │ └── prompt
│ │ │ ├── auth.js
│ │ │ └── db.js
│ │ └── orm
│ │ ├── orm.js
│ │ └── mongoDB.js
└── yonode-templates
│ ├── JS-NoDB-Template
│ ├── src
│ │ ├── utils
│ │ │ └── utils.js
│ │ ├── middlewares
│ │ │ └── middleware.js
│ │ ├── config
│ │ │ └── initialConfig.js
│ │ ├── controllers
│ │ │ └── helloWorldController.js
│ │ └── routes
│ │ │ └── helloWorldRoutes.js
│ ├── .gitignore
│ ├── Dockerfile
│ ├── docker-compose.yaml
│ ├── package.json
│ └── README.md
│ ├── JS-MongoDB-TypeORM-Auth-Template
│ ├── src
│ │ ├── utils
│ │ │ ├── utils.js
│ │ │ └── passwordUtils.js
│ │ ├── config
│ │ │ ├── initialConfig.js
│ │ │ └── dbConfig.js
│ │ ├── entity
│ │ │ └── User.js
│ │ └── routes
│ │ │ └── authRoutes.js
│ ├── Dockerfile
│ ├── README.md
│ ├── .gitignore
│ └── package.json
│ ├── JS-MySQL-TypeORM-Auth-Template
│ ├── src
│ │ ├── utils
│ │ │ ├── utils.js
│ │ │ └── passwordUtils.js
│ │ ├── config
│ │ │ ├── initialConfig.js
│ │ │ └── dbConfig.js
│ │ ├── entity
│ │ │ └── User.js
│ │ └── routes
│ │ │ └── authRoutes.js
│ ├── Dockerfile
│ ├── README.md
│ ├── .gitignore
│ └── package.json
│ ├── JS-MySQL-TypeORM-NoAuth-Template
│ ├── src
│ │ ├── utils
│ │ │ └── utils.js
│ │ ├── middlewares
│ │ │ └── middleware.js
│ │ ├── config
│ │ │ ├── initialConfig.js
│ │ │ └── dbConfig.js
│ │ ├── routes
│ │ │ └── helloWorldRoutes.js
│ │ ├── entity
│ │ │ └── entity.js
│ │ └── controllers
│ │ │ └── helloWorldController.js
│ ├── Dockerfile
│ ├── README.md
│ └── .gitignore
│ ├── typescript
│ ├── MongoDB
│ │ ├── Prisma
│ │ │ ├── Noauth
│ │ │ │ ├── src
│ │ │ │ │ ├── utils
│ │ │ │ │ │ └── utils.ts
│ │ │ │ │ ├── middlewares
│ │ │ │ │ │ └── middleware.ts
│ │ │ │ │ ├── routes
│ │ │ │ │ │ └── router.ts
│ │ │ │ │ ├── config
│ │ │ │ │ │ └── initial.config.ts
│ │ │ │ │ ├── controllers
│ │ │ │ │ │ └── controller.ts
│ │ │ │ │ └── app.ts
│ │ │ │ ├── .gitignore
│ │ │ │ ├── dist
│ │ │ │ │ ├── utils
│ │ │ │ │ │ ├── utils.js
│ │ │ │ │ │ └── utils.js.map
│ │ │ │ │ ├── middlewares
│ │ │ │ │ │ ├── middleware.js
│ │ │ │ │ │ └── middleware.js.map
│ │ │ │ │ ├── routes
│ │ │ │ │ │ ├── router.js
│ │ │ │ │ │ └── router.js.map
│ │ │ │ │ ├── controllers
│ │ │ │ │ │ ├── controller.js
│ │ │ │ │ │ └── controller.js.map
│ │ │ │ │ ├── config
│ │ │ │ │ │ ├── initial.config.js
│ │ │ │ │ │ └── initial.config.js.map
│ │ │ │ │ ├── app.js
│ │ │ │ │ └── app.js.map
│ │ │ │ ├── tsconfig.json
│ │ │ │ └── prisma
│ │ │ │ │ └── schema.prisma
│ │ │ └── Auth
│ │ │ │ ├── .gitignore
│ │ │ │ ├── src
│ │ │ │ ├── config
│ │ │ │ │ └── initial.config.js
│ │ │ │ ├── prisma
│ │ │ │ │ └── schema.prisma
│ │ │ │ └── app.js
│ │ │ │ └── package.json
│ │ ├── Mongoose
│ │ │ └── NoAuth
│ │ │ │ ├── src
│ │ │ │ ├── utils
│ │ │ │ │ └── utils.ts
│ │ │ │ ├── middlewares
│ │ │ │ │ └── middleware.ts
│ │ │ │ ├── routes
│ │ │ │ │ └── router.ts
│ │ │ │ ├── controllers
│ │ │ │ │ └── controller.ts
│ │ │ │ ├── config
│ │ │ │ │ ├── initial.config.ts
│ │ │ │ │ └── db.config.ts
│ │ │ │ ├── models
│ │ │ │ │ └── model.ts
│ │ │ │ └── app.ts
│ │ │ │ ├── .gitignore
│ │ │ │ ├── tsconfig.json
│ │ │ │ └── README.md
│ │ └── TypeORM
│ │ │ ├── noAuth
│ │ │ ├── src
│ │ │ │ ├── middleware
│ │ │ │ │ └── middleware.ts
│ │ │ │ ├── routes
│ │ │ │ │ └── route.ts
│ │ │ │ ├── entity
│ │ │ │ │ └── Entity.ts
│ │ │ │ ├── controller
│ │ │ │ │ └── controller.ts
│ │ │ │ ├── config
│ │ │ │ │ ├── initial.config.ts
│ │ │ │ │ └── db.config.ts
│ │ │ │ └── app.ts
│ │ │ ├── .gitignore
│ │ │ ├── tsconfig.json
│ │ │ └── README.md
│ │ │ └── Auth
│ │ │ ├── README.md
│ │ │ ├── .gitignore
│ │ │ └── src
│ │ │ ├── utils
│ │ │ └── generations.js
│ │ │ ├── routes
│ │ │ └── user.router.js
│ │ │ └── config
│ │ │ ├── initial.config.js
│ │ │ └── db.config.js
│ ├── MySQL
│ │ ├── Sequelize
│ │ │ └── NoAuth
│ │ │ │ ├── src
│ │ │ │ ├── utils
│ │ │ │ │ └── utils.ts
│ │ │ │ ├── middlewares
│ │ │ │ │ └── middleware.ts
│ │ │ │ ├── routes
│ │ │ │ │ └── router.ts
│ │ │ │ ├── models
│ │ │ │ │ ├── models.ts
│ │ │ │ │ └── model.ts
│ │ │ │ ├── controllers
│ │ │ │ │ └── controller.ts
│ │ │ │ ├── config
│ │ │ │ │ ├── initial.config.ts
│ │ │ │ │ └── db.config.ts
│ │ │ │ └── app.ts
│ │ │ │ ├── .gitignore
│ │ │ │ ├── tsconfig.json
│ │ │ │ └── README.md
│ │ ├── prisma
│ │ │ └── Noauth
│ │ │ │ ├── src
│ │ │ │ ├── utils
│ │ │ │ │ └── utils.ts
│ │ │ │ ├── middlewares
│ │ │ │ │ └── middleware.ts
│ │ │ │ ├── routes
│ │ │ │ │ └── router.ts
│ │ │ │ ├── config
│ │ │ │ │ └── initial.config.ts
│ │ │ │ ├── controllers
│ │ │ │ │ └── controller.ts
│ │ │ │ └── app.ts
│ │ │ │ ├── .gitignore
│ │ │ │ ├── tsconfig.json
│ │ │ │ ├── prisma
│ │ │ │ └── schema.prisma
│ │ │ │ └── README.md
│ │ └── TypeOrm
│ │ │ └── noAuth
│ │ │ ├── src
│ │ │ ├── middleware
│ │ │ │ └── middleware.ts
│ │ │ ├── routes
│ │ │ │ └── route.ts
│ │ │ ├── entity
│ │ │ │ └── Entity.ts
│ │ │ ├── controller
│ │ │ │ └── controller.ts
│ │ │ ├── config
│ │ │ │ ├── initial.config.ts
│ │ │ │ └── db.config.ts
│ │ │ └── app.ts
│ │ │ ├── .gitignore
│ │ │ ├── tsconfig.json
│ │ │ └── README.md
│ └── PostgreSQL
│ │ ├── Prisma
│ │ └── Noauth
│ │ │ ├── src
│ │ │ ├── utils
│ │ │ │ └── utils.ts
│ │ │ ├── middlewares
│ │ │ │ └── middleware.ts
│ │ │ ├── routes
│ │ │ │ └── router.ts
│ │ │ ├── config
│ │ │ │ └── initial.config.ts
│ │ │ ├── controllers
│ │ │ │ └── controller.ts
│ │ │ └── app.ts
│ │ │ ├── .gitignore
│ │ │ ├── tsconfig.json
│ │ │ ├── prisma
│ │ │ ├── client.js
│ │ │ └── schema.prisma
│ │ │ └── README.md
│ │ ├── Sequelize
│ │ └── NoAuth
│ │ │ ├── src
│ │ │ ├── utils
│ │ │ │ └── utils.ts
│ │ │ ├── middlewares
│ │ │ │ └── middleware.ts
│ │ │ ├── models
│ │ │ │ ├── models.ts
│ │ │ │ └── model.ts
│ │ │ ├── routes
│ │ │ │ └── router.ts
│ │ │ ├── controllers
│ │ │ │ └── controller.ts
│ │ │ ├── config
│ │ │ │ ├── initial.config.ts
│ │ │ │ └── db.config.ts
│ │ │ └── app.ts
│ │ │ ├── .gitignore
│ │ │ ├── tsconfig.json
│ │ │ └── README.md
│ │ └── TypeOrm
│ │ └── noAuth
│ │ ├── src
│ │ ├── middleware
│ │ │ └── middleware.ts
│ │ ├── routes
│ │ │ └── route.ts
│ │ ├── entity
│ │ │ └── Entity.ts
│ │ ├── controller
│ │ │ └── controller.ts
│ │ ├── config
│ │ │ ├── initial.config.ts
│ │ │ └── db.config.ts
│ │ └── app.ts
│ │ ├── .gitignore
│ │ ├── tsconfig.json
│ │ └── README.md
│ ├── JS-MongoDB-Mongoose-NoAuth-Template
│ ├── src
│ │ ├── utils
│ │ │ └── utils.js
│ │ ├── middlewares
│ │ │ └── middleware.js
│ │ ├── models
│ │ │ └── model.js
│ │ ├── config
│ │ │ ├── initialConfig.js
│ │ │ └── dbConfig.js
│ │ ├── controllers
│ │ │ └── helloWorldController.js
│ │ └── routes
│ │ │ └── helloWorldRoutes.js
│ ├── Dockerfile
│ ├── README.md
│ ├── package.json
│ └── .gitignore
│ ├── JS-MongoDB-TypeORM-NoAuth-Template
│ ├── src
│ │ ├── utils
│ │ │ └── utils.js
│ │ ├── middlewares
│ │ │ └── middleware.js
│ │ ├── config
│ │ │ ├── initialConfig.js
│ │ │ └── dbConfig.js
│ │ ├── routes
│ │ │ └── helloWorldRoutes.js
│ │ ├── entity
│ │ │ └── entity.js
│ │ └── controllers
│ │ │ └── helloWorldController.js
│ ├── Dockerfile
│ ├── README.md
│ └── .gitignore
│ ├── JS-MySQL-Sequelize-NoAuth-Template
│ ├── src
│ │ ├── utils
│ │ │ └── utils.js
│ │ ├── middlewares
│ │ │ └── middleware.js
│ │ ├── models
│ │ │ ├── models.js
│ │ │ └── model.js
│ │ ├── config
│ │ │ ├── initialConfig.js
│ │ │ └── dbConfig.js
│ │ ├── controllers
│ │ │ └── helloWorldController.js
│ │ └── routes
│ │ │ └── helloWorldRoutes.js
│ ├── Dockerfile
│ ├── README.md
│ └── .gitignore
│ ├── JS-PostgreSQL-TypeORM-NoAuth-Template
│ ├── src
│ │ ├── utils
│ │ │ └── utils.js
│ │ ├── middlewares
│ │ │ └── middleware.js
│ │ ├── config
│ │ │ ├── initialConfig.js
│ │ │ └── dbConfig.js
│ │ ├── controllers
│ │ │ └── helloWorldController.js
│ │ ├── routes
│ │ │ └── helloWorldRoutes.js
│ │ └── entity
│ │ │ └── entity.js
│ ├── Dockerfile
│ ├── README.md
│ ├── docker-compose.yaml
│ └── .gitignore
│ ├── JS-MySQL-Prisma-NoAuth-Template
│ ├── src
│ │ ├── middlewares
│ │ │ └── middleware.js
│ │ ├── config
│ │ │ └── initialConfig.js
│ │ ├── controllers
│ │ │ └── helloWorldController.js
│ │ └── routes
│ │ │ └── helloWorldRoutes.js
│ ├── Dockerfile
│ ├── prisma
│ │ ├── client.js
│ │ └── schema.prisma
│ ├── README.md
│ ├── docker-compose.yaml
│ └── .gitignore
│ ├── JS-PostgreSQL-Sequelize-NoAuth-Template
│ ├── src
│ │ ├── utils
│ │ │ └── utils.js
│ │ ├── middlewares
│ │ │ └── middleware.js
│ │ ├── models
│ │ │ ├── models.js
│ │ │ └── model.js
│ │ ├── config
│ │ │ ├── initialConfig.js
│ │ │ └── dbConfig.js
│ │ ├── routes
│ │ │ └── helloWorldRoutes.js
│ │ └── controllers
│ │ │ └── helloWorldController.js
│ ├── Dockerfile
│ ├── README.md
│ ├── docker-compose.yaml
│ └── .gitignore
│ ├── JS-MongoDB-Prisma-NoAuth-Template
│ ├── src
│ │ ├── middlewares
│ │ │ └── middleware.js
│ │ ├── config
│ │ │ └── initialConfig.js
│ │ ├── controllers
│ │ │ └── helloWorldController.js
│ │ └── routes
│ │ │ └── helloWorldRoutes.js
│ ├── Dockerfile
│ ├── prisma
│ │ ├── client.js
│ │ └── schema.prisma
│ ├── README.md
│ └── .gitignore
│ ├── JS-PostgreSQL-Prisma-NoAuth-Template
│ ├── src
│ │ ├── middlewares
│ │ │ └── middleware.js
│ │ ├── config
│ │ │ └── initialConfig.js
│ │ ├── controllers
│ │ │ └── helloWorldController.js
│ │ └── routes
│ │ │ └── helloWorldRoutes.js
│ ├── Dockerfile
│ ├── prisma
│ │ ├── client.js
│ │ └── schema.prisma
│ ├── README.md
│ ├── docker-compose.yaml
│ └── .gitignore
│ ├── JS-MySQL-Sequelize-Auth-Template
│ ├── src
│ │ ├── models
│ │ │ ├── models.js
│ │ │ └── User.js
│ │ ├── config
│ │ │ ├── initailConfig.js
│ │ │ └── dbConfig.js
│ │ ├── routes
│ │ │ └── authRoutes.js
│ │ └── utils
│ │ │ └── passwordUtils.js
│ ├── Dockerfile
│ ├── README.md
│ └── .gitIgnore
│ ├── JS-PostgreSQL-Sequelize-Auth-Template
│ ├── src
│ │ ├── models
│ │ │ ├── models.js
│ │ │ └── User.js
│ │ ├── config
│ │ │ └── initialConfig.js
│ │ ├── routes
│ │ │ └── authRoutes.js
│ │ └── utils
│ │ │ └── passwordUtils.js
│ ├── Dockerfile
│ ├── README.md
│ ├── .gitignore
│ └── docker-compose.yaml
│ ├── JS-MongoDB-Mongoose-Auth-Template
│ ├── Dockerfile
│ ├── src
│ │ ├── config
│ │ │ ├── initialConfig.js
│ │ │ └── dbConfig.js
│ │ ├── models
│ │ │ └── User.js
│ │ ├── routes
│ │ │ └── authRoutes.js
│ │ └── utils
│ │ │ └── passwordUtils.js
│ ├── README.md
│ ├── package.json
│ ├── .gitignore
│ └── docker-compose.yaml
│ ├── JS-PostgreSQL-TypeORM-Auth-Template
│ ├── Dockerfile
│ ├── src
│ │ ├── config
│ │ │ ├── initialConfig.js
│ │ │ └── dbConfig.js
│ │ ├── entity
│ │ │ └── User.js
│ │ ├── routes
│ │ │ └── authRoutes.js
│ │ └── utils
│ │ │ └── passwordUtils.js
│ ├── README.md
│ ├── .gitignore
│ ├── docker-compose.yaml
│ └── package.json
│ ├── JS-MongoDB-Prisma-Auth-Template
│ ├── Dockerfile
│ ├── src
│ │ ├── config
│ │ │ └── initialConfig.js
│ │ ├── routes
│ │ │ └── authRoutes.js
│ │ └── utils
│ │ │ └── passwordUtils.js
│ ├── prisma
│ │ ├── client.js
│ │ └── schema.prisma
│ ├── README.md
│ ├── .gitignore
│ └── package.json
│ ├── JS-MySQL-Prisma-Auth-Template
│ ├── Dockerfile
│ ├── src
│ │ ├── config
│ │ │ └── initailConfig.js
│ │ ├── routes
│ │ │ └── authRoutes.js
│ │ └── utils
│ │ │ └── passwordUtils.js
│ ├── prisma
│ │ ├── client.js
│ │ └── schema.prisma
│ ├── README.md
│ ├── docker-compose.yaml
│ ├── .gitignore
│ └── package.json
│ └── JS-PostgreSQL-Prisma-Auth-Template
│ ├── Dockerfile
│ ├── src
│ ├── config
│ │ └── initialConfig.js
│ ├── routes
│ │ └── authRoutes.js
│ └── utils
│ │ └── passwordUtils.js
│ ├── prisma
│ ├── client.js
│ └── schema.prisma
│ ├── docker-compose.yaml
│ ├── .gitignore
│ └── README.md
├── .eslintignore
├── yonode.org
├── components
│ ├── faq
│ │ └── index.ts
│ ├── hero
│ │ └── index.ts
│ ├── seo
│ │ ├── index.ts
│ │ └── seo.tsx
│ ├── layout
│ │ ├── index.ts
│ │ └── theme-toggle.tsx
│ ├── features
│ │ └── index.ts
│ ├── nav-link
│ │ ├── index.ts
│ │ └── nav-link.tsx
│ ├── button-link
│ │ ├── index.ts
│ │ └── button-link.tsx
│ ├── highlights
│ │ └── index.ts
│ ├── mobile-nav
│ │ └── index.ts
│ ├── announcement-banner
│ │ └── index.ts
│ ├── section
│ │ ├── index.ts
│ │ └── section.tsx
│ ├── testimonials
│ │ ├── index.ts
│ │ └── testimonials.tsx
│ ├── logos
│ │ └── index.ts
│ ├── motion
│ │ ├── box.tsx
│ │ ├── page-transition.tsx
│ │ ├── fall-in-place.tsx
│ │ └── float.tsx
│ └── typography
│ │ └── index.tsx
├── README.md
├── public
│ └── static
│ │ ├── images
│ │ ├── avatar.jpg
│ │ ├── avatar2.jpg
│ │ ├── avatar3.jpg
│ │ └── eelco.jpg
│ │ ├── favicons
│ │ ├── favicon.ico
│ │ ├── apple-icon.png
│ │ ├── favicon-16x16.png
│ │ ├── favicon-32x32.png
│ │ ├── favicon-96x96.png
│ │ ├── ms-icon-144x144.png
│ │ ├── ms-icon-150x150.png
│ │ ├── ms-icon-310x310.png
│ │ ├── ms-icon-70x70.png
│ │ ├── apple-icon-57x57.png
│ │ ├── apple-icon-60x60.png
│ │ ├── apple-icon-72x72.png
│ │ ├── apple-icon-76x76.png
│ │ ├── android-icon-144x144.png
│ │ ├── android-icon-192x192.png
│ │ ├── android-icon-36x36.png
│ │ ├── android-icon-48x48.png
│ │ ├── android-icon-72x72.png
│ │ ├── android-icon-96x96.png
│ │ ├── apple-icon-114x114.png
│ │ ├── apple-icon-120x120.png
│ │ ├── apple-icon-144x144.png
│ │ ├── apple-icon-152x152.png
│ │ ├── apple-icon-180x180.png
│ │ ├── apple-icon-precomposed.png
│ │ └── browserconfig.xml
│ │ └── screenshots
│ │ ├── demo.png
│ │ ├── list.png
│ │ ├── billing.png
│ │ ├── dashboard.png
│ │ └── landingspage.png
├── .eslintrc.json
├── next-env.d.ts
├── data
│ └── logo.tsx
├── theme
│ ├── components
│ │ ├── index.ts
│ │ ├── section.ts
│ │ ├── button.ts
│ │ └── cta.ts
│ ├── foundations
│ │ └── typography.ts
│ └── index.ts
├── pages
│ ├── api
│ │ └── hello.ts
│ └── _app.tsx
├── .gitignore
├── hooks
│ └── use-route-changed.ts
└── contentlayer.config.ts
├── docs.yonode.org
├── .gitignore
├── README.md
├── .github
│ └── images
│ │ ├── orm.png
│ │ ├── auth.png
│ │ ├── name.png
│ │ ├── congrats.png
│ │ ├── database.png
│ │ ├── language.png
│ │ └── installation.png
├── pages
│ ├── about.mdx
│ └── _meta.json
├── next.config.js
├── next-env.d.ts
├── tsconfig.json
└── package.json
├── assets
└── yonode-icon.png
├── pnpm-workspace.yaml
├── .prettierrc
├── .editorconfig
├── .github
├── ISSUE_TEMPLATE
│ └── config.yml
└── workflows
│ └── publish.yaml
├── eslint.config.mjs
├── .gitignore
├── SECURITY.md
├── .eslintrc.js
├── renovate.json5
└── package.json
/.prettierignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | build
3 |
--------------------------------------------------------------------------------
/packages/yonode/.gitignore:
--------------------------------------------------------------------------------
1 | /node_modules/
2 |
--------------------------------------------------------------------------------
/.eslintignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | dist
3 | build
4 | temp
5 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-NoDB-Template/src/utils/utils.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/yonode.org/components/faq/index.ts:
--------------------------------------------------------------------------------
1 | export * from './faq'
2 |
--------------------------------------------------------------------------------
/yonode.org/components/hero/index.ts:
--------------------------------------------------------------------------------
1 | export * from './hero'
2 |
--------------------------------------------------------------------------------
/yonode.org/components/seo/index.ts:
--------------------------------------------------------------------------------
1 | export * from './seo'
2 |
--------------------------------------------------------------------------------
/docs.yonode.org/.gitignore:
--------------------------------------------------------------------------------
1 | .next
2 | node_modules
3 | .vscode
4 |
--------------------------------------------------------------------------------
/yonode.org/components/layout/index.ts:
--------------------------------------------------------------------------------
1 | export * from './layout'
2 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-NoDB-Template/src/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/yonode.org/components/features/index.ts:
--------------------------------------------------------------------------------
1 | export * from './features'
2 |
--------------------------------------------------------------------------------
/yonode.org/components/nav-link/index.ts:
--------------------------------------------------------------------------------
1 | export * from './nav-link'
2 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-Auth-Template/src/utils/utils.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-Auth-Template/src/utils/utils.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-NoAuth-Template/src/utils/utils.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/src/utils/utils.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/src/utils/utils.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/prisma/Noauth/src/utils/utils.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/yonode.org/components/button-link/index.ts:
--------------------------------------------------------------------------------
1 | export * from './button-link'
2 |
--------------------------------------------------------------------------------
/yonode.org/components/highlights/index.ts:
--------------------------------------------------------------------------------
1 | export * from './highlights'
2 |
--------------------------------------------------------------------------------
/yonode.org/components/mobile-nav/index.ts:
--------------------------------------------------------------------------------
1 | export * from './mobile-nav'
2 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/src/utils/utils.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-NoAuth-Template/src/utils/utils.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/src/utils/utils.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/src/utils/utils.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/src/utils/utils.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/src/utils/utils.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/src/utils/utils.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-NoAuth-Template/src/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-NoAuth-Template/src/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/src/utils/utils.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/src/middlewares/middleware.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/noAuth/src/middleware/middleware.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/TypeOrm/noAuth/src/middleware/middleware.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/prisma/Noauth/src/middlewares/middleware.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/yonode.org/README.md:
--------------------------------------------------------------------------------
1 | # Yonode
2 |
3 | The Node.js Toolkit for Rapid Development
4 |
--------------------------------------------------------------------------------
/docs.yonode.org/README.md:
--------------------------------------------------------------------------------
1 | # Yonode
2 |
3 | The Node.js Toolkit for Rapid Development
4 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/src/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-NoAuth-Template/src/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-NoAuth-Template/src/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/src/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-NoDB-Template/.gitignore:
--------------------------------------------------------------------------------
1 | .vscode
2 | /node_modules
3 | .env
4 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-NoAuth-Template/src/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/src/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/src/middlewares/middleware.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Auth/.gitignore:
--------------------------------------------------------------------------------
1 | /node_modules
2 | .env
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/Auth/README.md:
--------------------------------------------------------------------------------
1 | new one first time
2 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/src/middlewares/middleware.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/src/middlewares/middleware.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/TypeOrm/noAuth/src/middleware/middleware.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/yonode.org/components/announcement-banner/index.ts:
--------------------------------------------------------------------------------
1 | export * from './announcement-banner'
2 |
--------------------------------------------------------------------------------
/assets/yonode-icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/assets/yonode-icon.png
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-Auth-Template/src/models/models.js:
--------------------------------------------------------------------------------
1 | import "./User.js";
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/src/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/src/middlewares/middleware.ts:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/pnpm-workspace.yaml:
--------------------------------------------------------------------------------
1 | packages:
2 | - 'packages/*'
3 | - 'yonode.org'
4 | - 'docs.yonode.org'
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-Auth-Template/src/models/models.js:
--------------------------------------------------------------------------------
1 | import "./User.js";
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/.gitignore:
--------------------------------------------------------------------------------
1 | /node_modules
2 | .env
3 | /dist
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | .env
3 | dest
4 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | .env
3 | dist
4 |
--------------------------------------------------------------------------------
/yonode.org/components/section/index.ts:
--------------------------------------------------------------------------------
1 | export * from './section'
2 | export * from './section-title'
3 |
--------------------------------------------------------------------------------
/yonode.org/components/testimonials/index.ts:
--------------------------------------------------------------------------------
1 | export * from './testimonial'
2 | export * from './testimonials'
3 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | .env
3 | .vscode/*
4 | /dist
--------------------------------------------------------------------------------
/yonode.org/components/logos/index.ts:
--------------------------------------------------------------------------------
1 | export * from './chakra'
2 | export * from './next'
3 | export * from './react'
4 |
--------------------------------------------------------------------------------
/docs.yonode.org/.github/images/orm.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/docs.yonode.org/.github/images/orm.png
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/utils/utils.js:
--------------------------------------------------------------------------------
1 | export {};
2 | //# sourceMappingURL=utils.js.map
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | .env
3 | .vscode/*
4 | /dist
5 |
--------------------------------------------------------------------------------
/docs.yonode.org/.github/images/auth.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/docs.yonode.org/.github/images/auth.png
--------------------------------------------------------------------------------
/docs.yonode.org/.github/images/name.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/docs.yonode.org/.github/images/name.png
--------------------------------------------------------------------------------
/docs.yonode.org/.github/images/congrats.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/docs.yonode.org/.github/images/congrats.png
--------------------------------------------------------------------------------
/docs.yonode.org/.github/images/database.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/docs.yonode.org/.github/images/database.png
--------------------------------------------------------------------------------
/docs.yonode.org/.github/images/language.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/docs.yonode.org/.github/images/language.png
--------------------------------------------------------------------------------
/yonode.org/public/static/images/avatar.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/images/avatar.jpg
--------------------------------------------------------------------------------
/yonode.org/public/static/images/avatar2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/images/avatar2.jpg
--------------------------------------------------------------------------------
/yonode.org/public/static/images/avatar3.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/images/avatar3.jpg
--------------------------------------------------------------------------------
/yonode.org/public/static/images/eelco.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/images/eelco.jpg
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/middlewares/middleware.js:
--------------------------------------------------------------------------------
1 | export {};
2 | //# sourceMappingURL=middleware.js.map
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/favicon.ico
--------------------------------------------------------------------------------
/yonode.org/public/static/screenshots/demo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/screenshots/demo.png
--------------------------------------------------------------------------------
/yonode.org/public/static/screenshots/list.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/screenshots/list.png
--------------------------------------------------------------------------------
/docs.yonode.org/.github/images/installation.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/docs.yonode.org/.github/images/installation.png
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/Auth/.gitignore:
--------------------------------------------------------------------------------
1 | .idea/
2 | .vscode/
3 | node_modules/
4 | build/
5 | tmp/
6 | temp/
7 | .env
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/noAuth/.gitignore:
--------------------------------------------------------------------------------
1 | .idea/
2 | .vscode/
3 | node_modules/
4 | build/
5 | tmp/
6 | temp/
7 | .env
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/TypeOrm/noAuth/.gitignore:
--------------------------------------------------------------------------------
1 | .idea/
2 | .vscode/
3 | node_modules/
4 | build/
5 | tmp/
6 | temp/
7 | .env
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon.png
--------------------------------------------------------------------------------
/yonode.org/public/static/screenshots/billing.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/screenshots/billing.png
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/TypeOrm/noAuth/.gitignore:
--------------------------------------------------------------------------------
1 | .idea/
2 | .vscode/
3 | node_modules/
4 | build/
5 | tmp/
6 | temp/
7 | .env
--------------------------------------------------------------------------------
/yonode.org/public/static/screenshots/dashboard.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/screenshots/dashboard.png
--------------------------------------------------------------------------------
/yonode.org/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "next/core-web-vitals",
3 | "rules": {
4 | "import/no-anonymous-default-export": "off"
5 | }
6 | }
7 |
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/favicon-16x16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/favicon-16x16.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/favicon-32x32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/favicon-32x32.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/favicon-96x96.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/favicon-96x96.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/ms-icon-144x144.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/ms-icon-144x144.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/ms-icon-150x150.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/ms-icon-150x150.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/ms-icon-310x310.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/ms-icon-310x310.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/ms-icon-70x70.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/ms-icon-70x70.png
--------------------------------------------------------------------------------
/yonode.org/public/static/screenshots/landingspage.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/screenshots/landingspage.png
--------------------------------------------------------------------------------
/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "semi": false,
3 | "singleQuote": true,
4 | "trailingComma": "es5",
5 | "tabWidth": 2,
6 | "printWidth": 80
7 | }
8 |
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon-57x57.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon-57x57.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon-60x60.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon-60x60.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon-72x72.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon-72x72.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon-76x76.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon-76x76.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/android-icon-144x144.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/android-icon-144x144.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/android-icon-192x192.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/android-icon-192x192.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/android-icon-36x36.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/android-icon-36x36.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/android-icon-48x48.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/android-icon-48x48.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/android-icon-72x72.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/android-icon-72x72.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/android-icon-96x96.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/android-icon-96x96.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon-114x114.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon-114x114.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon-120x120.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon-120x120.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon-144x144.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon-144x144.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon-152x152.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon-152x152.png
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon-180x180.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon-180x180.png
--------------------------------------------------------------------------------
/docs.yonode.org/pages/about.mdx:
--------------------------------------------------------------------------------
1 | # About
2 |
3 | Yonode is a Node.js framework that streamlines your workflow, enabling you to craft efficient server solutions rapidly.
4 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/prisma/Noauth/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | # Keep environment variables out of version control
3 | .env
4 | .vscode/*
5 | /dist
6 |
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/apple-icon-precomposed.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/sharafdin/yonode/HEAD/yonode.org/public/static/favicons/apple-icon-precomposed.png
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-NoDB-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/src/routes/router.ts:
--------------------------------------------------------------------------------
1 | import express from "express";
2 |
3 | const routerName = express.Router();
4 |
5 | export default routerName;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Auth/src/config/initial.config.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 | dotenv.config();
3 |
4 | export const port = process.env.PORT || 5000;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/utils/utils.js.map:
--------------------------------------------------------------------------------
1 | {"version":3,"file":"utils.js","sourceRoot":"","sources":["../../src/utils/utils.ts"],"names":[],"mappings":""}
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/src/routes/router.ts:
--------------------------------------------------------------------------------
1 | import express from "express";
2 |
3 | const routerName = express.Router();
4 |
5 | export default routerName;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/noAuth/src/routes/route.ts:
--------------------------------------------------------------------------------
1 | import express from "express";
2 |
3 | const routerName = express.Router();
4 |
5 | export default routerName;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/src/routes/router.ts:
--------------------------------------------------------------------------------
1 | import express from "express";
2 |
3 | const routerName = express.Router();
4 |
5 | export default routerName;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/TypeOrm/noAuth/src/routes/route.ts:
--------------------------------------------------------------------------------
1 | import express from "express";
2 |
3 | const routerName = express.Router();
4 |
5 | export default routerName;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/prisma/Noauth/src/routes/router.ts:
--------------------------------------------------------------------------------
1 | import express from "express";
2 |
3 | const routerName = express.Router();
4 |
5 | export default routerName;
--------------------------------------------------------------------------------
/docs.yonode.org/next.config.js:
--------------------------------------------------------------------------------
1 | const withNextra = require('nextra')({
2 | theme: 'nextra-theme-docs',
3 | themeConfig: './theme.config.tsx',
4 | })
5 |
6 | module.exports = withNextra()
7 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/src/models/models.js:
--------------------------------------------------------------------------------
1 | import modelName from "./model.js";
2 |
3 | const models = {
4 | modelName
5 | }
6 |
7 | export default models;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/src/models/models.ts:
--------------------------------------------------------------------------------
1 | import modelName from "./model";
2 |
3 | const models = {
4 | modelName
5 | }
6 |
7 | export default models;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/src/routes/router.ts:
--------------------------------------------------------------------------------
1 | import express from "express";
2 |
3 | const routerName = express.Router();
4 |
5 | export default routerName;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/TypeOrm/noAuth/src/routes/route.ts:
--------------------------------------------------------------------------------
1 | import express from "express";
2 |
3 | const routerName = express.Router();
4 |
5 | export default routerName;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/src/models/models.js:
--------------------------------------------------------------------------------
1 | import modelName from './model.js'
2 |
3 | const models = {
4 | modelName
5 | }
6 |
7 | export default models;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/prisma/Noauth/src/config/initial.config.ts:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/src/models/models.ts:
--------------------------------------------------------------------------------
1 | import modelName from "./model";
2 |
3 | const models = {
4 | modelName
5 | }
6 |
7 | export default models;
--------------------------------------------------------------------------------
/.editorconfig:
--------------------------------------------------------------------------------
1 | root = true
2 |
3 | [*]
4 | charset = utf-8
5 | indent_style = space
6 | indent_size = 2
7 | end_of_line = lf
8 | trim_trailing_whitespace = true
9 | insert_final_newline = true
10 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/src/config/initial.config.ts:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/src/config/initial.config.ts:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-NoAuth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 |
7 |
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-NoAuth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 |
7 |
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/src/routes/router.ts:
--------------------------------------------------------------------------------
1 | import express, { Router } from "express";
2 |
3 | const routerName:Router = express.Router();
4 |
5 | export default routerName;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-NoAuth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 |
7 |
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/middlewares/middleware.js.map:
--------------------------------------------------------------------------------
1 | {"version":3,"file":"middleware.js","sourceRoot":"","sources":["../../src/middlewares/middleware.ts"],"names":[],"mappings":""}
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/routes/router.js:
--------------------------------------------------------------------------------
1 | import express from "express";
2 | const routerName = express.Router();
3 | export default routerName;
4 | //# sourceMappingURL=router.js.map
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/src/models/model.js:
--------------------------------------------------------------------------------
1 | import sequelize from "../config/dbConfig.js";
2 |
3 | const modelName = sequelize.define('modelName', {
4 |
5 | });
6 |
7 | export default modelName;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/controllers/controller.js:
--------------------------------------------------------------------------------
1 | export const controller = async (req, res) => {
2 | try {
3 | }
4 | catch (error) { }
5 | };
6 | //# sourceMappingURL=controller.js.map
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/config/initial.config.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 | dotenv.config();
3 | export const port = process.env.SERVER_PORT || 8000;
4 | //# sourceMappingURL=initial.config.js.map
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/Auth/src/utils/generations.js:
--------------------------------------------------------------------------------
1 | export const generateVerificationToken = () => {
2 | return Math.random().toString(36).substring(2, 15) + Math.random().toString(36).substring(2, 15);
3 | };
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/noAuth/src/entity/Entity.ts:
--------------------------------------------------------------------------------
1 | import { Entity, ObjectIdColumn, ObjectId } from "typeorm";
2 |
3 | @Entity()
4 | export class EntityName {
5 | @ObjectIdColumn()
6 | _id: ObjectId;
7 | }
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/TypeOrm/noAuth/src/entity/Entity.ts:
--------------------------------------------------------------------------------
1 | import { Entity, PrimaryGeneratedColumn } from "typeorm";
2 |
3 | @Entity()
4 | export class EntityName {
5 | @PrimaryGeneratedColumn()
6 | id: number;
7 | }
8 |
--------------------------------------------------------------------------------
/yonode.org/next-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 | ///
3 |
4 | // NOTE: This file should not be edited
5 | // see https://nextjs.org/docs/basic-features/typescript for more information.
6 |
--------------------------------------------------------------------------------
/docs.yonode.org/next-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 | ///
3 |
4 | // NOTE: This file should not be edited
5 | // see https://nextjs.org/docs/basic-features/typescript for more information.
6 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/TypeOrm/noAuth/src/entity/Entity.ts:
--------------------------------------------------------------------------------
1 | import { Entity, PrimaryGeneratedColumn } from "typeorm";
2 |
3 | @Entity()
4 | export class EntityName {
5 | @PrimaryGeneratedColumn()
6 | id: number;
7 | }
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/src/controllers/controller.ts:
--------------------------------------------------------------------------------
1 | import { Request, Response } from "express";
2 |
3 | export const controller = async (req: Request, res: Response) => {
4 | try {
5 | } catch (error) {}
6 | };
7 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/noAuth/src/controller/controller.ts:
--------------------------------------------------------------------------------
1 | import { Request, Response } from "express";
2 |
3 | export const controller = async (req: Request, res: Response) => {
4 | try {
5 | } catch (error) {}
6 | };
7 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/TypeOrm/noAuth/src/controller/controller.ts:
--------------------------------------------------------------------------------
1 | import { Request, Response } from "express";
2 |
3 | export const controller = async (req: Request, res: Response) => {
4 | try {
5 | } catch (error) {}
6 | };
7 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/prisma/Noauth/src/controllers/controller.ts:
--------------------------------------------------------------------------------
1 | import { Request, Response } from "express";
2 |
3 | export const controller = async (req: Request, res: Response) => {
4 | try {
5 | } catch (error) {}
6 | };
7 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/src/controllers/controller.ts:
--------------------------------------------------------------------------------
1 | import { Request, Response } from "express";
2 |
3 | export const controller = async (req: Request, res: Response) => {
4 | try {
5 | } catch (error) {}
6 | };
7 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/src/controllers/controller.ts:
--------------------------------------------------------------------------------
1 | import { Request, Response } from "express";
2 |
3 | export const controller = async (req: Request, res: Response) => {
4 | try {
5 | } catch (error) {}
6 | };
7 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/TypeOrm/noAuth/src/controller/controller.ts:
--------------------------------------------------------------------------------
1 | import { Request, Response } from "express";
2 |
3 | export const controller = async (req: Request, res: Response) => {
4 | try {
5 | } catch (error) {}
6 | };
7 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/config.yml:
--------------------------------------------------------------------------------
1 | blank_issues_enabled: false
2 | contact_links:
3 | - name: Questions & Discussions
4 | url: https://github.com/sharafdin/yonode/discussions
5 | about: Use GitHub discussions for message-board style questions and discussions.
6 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/src/controllers/controller.ts:
--------------------------------------------------------------------------------
1 | import { Request, Response } from "express";
2 |
3 | export const controller = async (req: Request, res: Response) => {
4 | try {
5 |
6 | } catch (error) {
7 |
8 | }
9 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-NoDB-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/yonode.org/data/logo.tsx:
--------------------------------------------------------------------------------
1 | import { chakra, HTMLChakraProps, useColorModeValue } from '@chakra-ui/react'
2 |
3 | export const Logo: React.FC> = (props) => {
4 | const color = useColorModeValue('#231f20', '#fff')
5 | return (
6 | Yonode
7 | )
8 | }
9 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-Auth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/routes/router.js.map:
--------------------------------------------------------------------------------
1 | {"version":3,"file":"router.js","sourceRoot":"","sources":["../../src/routes/router.ts"],"names":[],"mappings":"AAAA,OAAO,OAAO,MAAM,SAAS,CAAC;AAE9B,MAAM,UAAU,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;AAEpC,eAAe,UAAU,CAAC"}
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/src/config/initial.config.ts:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL + process.env.DATABASE_NAME || "yonodeDB"
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/src/controllers/controller.ts:
--------------------------------------------------------------------------------
1 | import { Request , Response } from "express";
2 |
3 | export const controller = async (req: Request, res: Response) => {
4 | try {
5 |
6 | } catch (error) {
7 |
8 | }
9 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-Auth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-Auth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-NoAuth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-Auth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL + process.env.DATABASE_NAME || 'yonodeDB';
7 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-NoAuth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-NoDB-Template/docker-compose.yaml:
--------------------------------------------------------------------------------
1 | version: '3.9'
2 |
3 | services:
4 | server:
5 | build: .
6 | container_name: server
7 | restart: on-failure
8 | volumes:
9 | - .:/app
10 | - /app/node_modules
11 | ports:
12 | - '8000:8000'
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-Auth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/src/models/model.js:
--------------------------------------------------------------------------------
1 | import { sequelize } from '../config/dbConfig.js';
2 |
3 | const modelName = sequelize.define('modelName', {
4 | // rest of your schema here
5 |
6 | });
7 |
8 | export default modelName;
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-Auth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL + process.env.DATABASE_NAME || 'yonodeDB';
7 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/src/config/initial.config.ts:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL + process.env.DATABASE_NAME || "yonodeDB";
7 |
--------------------------------------------------------------------------------
/eslint.config.mjs:
--------------------------------------------------------------------------------
1 | import globals from "globals";
2 | import pluginJs from "@eslint/js";
3 | import tseslint from "typescript-eslint";
4 |
5 |
6 | export default [
7 | {languageOptions: { globals: globals.browser }},
8 | pluginJs.configs.recommended,
9 | ...tseslint.configs.recommended,
10 | ];
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/src/models/model.js:
--------------------------------------------------------------------------------
1 | import mongoose from "mongoose";
2 |
3 | const { Schema, model } = mongoose;
4 |
5 | const schemaName = new Schema({
6 |
7 | });
8 |
9 | const modelName = model("modelName", schemaName);
10 |
11 | export default modelName;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-NoDB-Template/src/controllers/helloWorldController.js:
--------------------------------------------------------------------------------
1 | export const helloWorld = async (req, res) => {
2 | try {
3 | res.send("Hello World!");
4 | } catch (error) {
5 | res.status(500).json({
6 | message: "Internal Server Error",
7 | });
8 | }
9 | };
10 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-NoDB-Template/src/routes/helloWorldRoutes.js:
--------------------------------------------------------------------------------
1 | import express from "express";
2 | import { helloWorld } from "../controllers/helloWorldController.js";
3 |
4 | const helloWorldRouter = express.Router();
5 |
6 | helloWorldRouter.get("/", helloWorld);
7 |
8 | export default helloWorldRouter;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-NoAuth-Template/src/controllers/helloWorldController.js:
--------------------------------------------------------------------------------
1 | export const helloWorld = async (req, res)=>{
2 | try{
3 | res.send("Hello world!")
4 | }
5 | catch(err){
6 | res.status(500).json({
7 | message: "Internal Server Error"
8 | })
9 | }
10 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-NoAuth-Template/src/controllers/helloWorldController.js:
--------------------------------------------------------------------------------
1 | export const helloWorld = async (req, res) => {
2 | try {
3 | res.send("Hello World!");
4 | } catch (error) {
5 | res.status(500).json({
6 | message: "Internal Server Error",
7 | });
8 | }
9 | };
--------------------------------------------------------------------------------
/docs.yonode.org/pages/_meta.json:
--------------------------------------------------------------------------------
1 | {
2 | "index": "Getting Started",
3 | "about": {
4 | "title": "About",
5 | "type": "page"
6 | },
7 | "contact": {
8 | "title": "Contact ↗",
9 | "type": "page",
10 | "href": "https://twitter.com/isasharafdin",
11 | "newWindow": true
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-NoAuth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || 'yonodeDB';
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-NoAuth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || 'yonodeDB';
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/src/config/initial.config.ts:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || 'yonodeDB';
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/noAuth/src/config/initial.config.ts:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || "yonodeDB";
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/TypeOrm/noAuth/src/config/initial.config.ts:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || "yonodeDB";
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || 'yonodeDB';
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-Auth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | RUN npx prisma generate
16 |
17 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-Auth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | RUN npx prisma generate
16 |
17 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-NoAuth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | RUN npx prisma generate
16 |
17 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-NoAuth-Template/src/routes/helloWorldRoutes.js:
--------------------------------------------------------------------------------
1 | import express from 'express'
2 | import { helloWorld } from '../controllers/helloWorldController.js'
3 |
4 | const helloWorldRouter = express.Router()
5 |
6 | helloWorldRouter.get("/", helloWorld)
7 |
8 | export default helloWorldRouter;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-NoAuth-Template/src/routes/helloWorldRoutes.js:
--------------------------------------------------------------------------------
1 | import express from 'express'
2 | import { helloWorld } from '../controllers/helloWorldController.js'
3 |
4 | const helloWorldRouter = express.Router()
5 |
6 | helloWorldRouter.get("/", helloWorld)
7 |
8 | export default helloWorldRouter;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || 'yonodeDB';
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/TypeOrm/noAuth/src/config/initial.config.ts:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || "yonodeDB";
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/src/controllers/helloWorldController.js:
--------------------------------------------------------------------------------
1 | export const helloWorld = async (req, res) => {
2 | try {
3 | res.send("Hello World!");
4 | } catch (error) {
5 | res.status(500).json({
6 | message: "Internal Server Error",
7 | });
8 | }
9 | };
10 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/src/routes/helloWorldRoutes.js:
--------------------------------------------------------------------------------
1 | import express from "express";
2 | import { helloWorld } from "../controllers/helloWorldController.js";
3 |
4 | const helloWorldRouter = express.Router();
5 |
6 | helloWorldRouter.get("/", helloWorld);
7 |
8 | export default helloWorldRouter;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-Auth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const jwtSecret = process.env.JWT_SECRET_KEY;
7 | export const nodeEnv = process.env.NODE_ENVIRONMENT || "development";
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-NoAuth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | RUN npx prisma generate
16 |
17 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-NoAuth-Template/src/controllers/helloWorldController.js:
--------------------------------------------------------------------------------
1 | export const helloWorld = async (req, res) => {
2 | try {
3 | res.send("Hello World!");
4 | } catch (error) {
5 | res.status(500).json({
6 | message: "Internal Server Error",
7 | });
8 | }
9 | };
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-NoAuth-Template/src/routes/helloWorldRoutes.js:
--------------------------------------------------------------------------------
1 | import express from 'express'
2 | import { helloWorld } from '../controllers/helloWorldController.js';
3 |
4 | const helloWorldRouter = express.Router()
5 |
6 | helloWorldRouter.get("/" , helloWorld)
7 |
8 | export default helloWorldRouter;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-Auth-Template/src/config/initailConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const jwtSecret = process.env.JWT_SECRET_KEY;
7 | export const nodeEnv = process.env.NODE_ENVIRONMENT || "development";
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/src/controllers/helloWorldController.js:
--------------------------------------------------------------------------------
1 | export const helloWorld = async (req, res) => {
2 | try {
3 | res.send("Hello World!");
4 | } catch (error) {
5 | res.status(500).json({
6 | message: "Internal Server Error",
7 | });
8 | }
9 | };
10 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-Auth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN npm install -g nodemon
12 |
13 | RUN pnpm install
14 |
15 | RUN npx prisma generate
16 |
17 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-NoAuth-Template/Dockerfile:
--------------------------------------------------------------------------------
1 | FROM node:21
2 |
3 | EXPOSE 8000
4 |
5 | WORKDIR /app
6 |
7 | COPY . .
8 |
9 | RUN npm install -g pnpm
10 |
11 | RUN pnpm install
12 |
13 | RUN npm install -g nodemon
14 |
15 | RUN npx prisma generate
16 |
17 | CMD ["nodemon", "-L", "./src/app.js"]
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-NoAuth-Template/src/routes/helloWorldRoutes.js:
--------------------------------------------------------------------------------
1 | import express from "express";
2 | import { helloWorld } from "../controllers/helloWorldController.js";
3 |
4 | const helloWorldRouter = express.Router();
5 |
6 | helloWorldRouter.get("/", helloWorld);
7 |
8 | export default helloWorldRouter;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/src/controllers/helloWorldController.js:
--------------------------------------------------------------------------------
1 | export const helloWorld = async (req, res) => {
2 | try {
3 | res.send("Hello World!");
4 | } catch (error) {
5 | res.status(500).json({
6 | message: "Internal Server Error",
7 | });
8 | }
9 | };
10 |
--------------------------------------------------------------------------------
/yonode.org/public/static/favicons/browserconfig.xml:
--------------------------------------------------------------------------------
1 |
2 | #ffffff
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-NoAuth-Template/src/routes/helloWorldRoutes.js:
--------------------------------------------------------------------------------
1 | import express from "express";
2 | import { helloWorld } from "../controllers/helloWorldController.js";
3 |
4 | const helloWorldRouter = express.Router();
5 |
6 | helloWorldRouter.get("/", helloWorld);
7 |
8 | export default helloWorldRouter;
9 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/src/routes/helloWorldRoutes.js:
--------------------------------------------------------------------------------
1 | import express from "express";
2 | import { helloWorld } from "../controllers/helloWorldController.js";
3 |
4 | const helloWorldRouter = express.Router();
5 |
6 | helloWorldRouter.get("/", helloWorld);
7 |
8 | export default helloWorldRouter;
9 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-Auth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const jwtSecret = process.env.JWT_SECRET_KEY;
7 | export const nodeEnv = process.env.NODE_ENVIRONMENT || "development";
8 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/src/routes/helloWorldRoutes.js:
--------------------------------------------------------------------------------
1 | import express from "express"
2 | import { helloWorld } from "../controllers/helloWorldController.js"
3 |
4 | const hellWorldRouter = express.Router()
5 |
6 | hellWorldRouter.get("/" , helloWorld)
7 |
8 | export default hellWorldRouter;
9 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/src/routes/helloWorldRoutes.js:
--------------------------------------------------------------------------------
1 | import express from "express";
2 | import { helloWorld } from "../controllers/helloWorldController.js";
3 |
4 | const helloWorldRouter = express.Router();
5 |
6 | helloWorldRouter.get("/", helloWorld);
7 |
8 | export default helloWorldRouter;
9 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/config/initial.config.js.map:
--------------------------------------------------------------------------------
1 | {"version":3,"file":"initial.config.js","sourceRoot":"","sources":["../../src/config/initial.config.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,QAAQ,CAAC;AAE5B,MAAM,CAAC,MAAM,EAAE,CAAC;AAEhB,MAAM,CAAC,MAAM,IAAI,GAAG,OAAO,CAAC,GAAG,CAAC,WAAW,IAAI,IAAI,CAAC"}
--------------------------------------------------------------------------------
/yonode.org/components/motion/box.tsx:
--------------------------------------------------------------------------------
1 | import { chakra, ChakraProps, HTMLChakraProps } from '@chakra-ui/react'
2 | import { motion, HTMLMotionProps } from 'framer-motion'
3 |
4 | export interface MotionBoxProps
5 | extends HTMLMotionProps<'div'>,
6 | Omit {}
7 |
8 | export const MotionBox = motion(chakra.div)
9 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/controllers/controller.js.map:
--------------------------------------------------------------------------------
1 | {"version":3,"file":"controller.js","sourceRoot":"","sources":["../../src/controllers/controller.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,UAAU,GAAG,KAAK,EAAE,GAAY,EAAE,GAAa,EAAE,EAAE;IAC9D,IAAI,CAAC;IACL,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC,CAAA,CAAC;AACpB,CAAC,CAAC"}
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "module": "NodeNext",
4 | "moduleResolution": "NodeNext",
5 | "target": "ES2020",
6 | "baseUrl": "src",
7 | "outDir": "./dist",
8 | "sourceMap": true,
9 | "noImplicitAny": true,
10 | },
11 | "include": ["src/**/*"],
12 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "module": "NodeNext",
4 | "moduleResolution": "NodeNext",
5 | "baseUrl": "src",
6 | "outDir": "./dist",
7 | "sourceMap": true,
8 | "noImplicitAny": true
9 | },
10 | "include": ["src/**/*"]
11 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/prisma/Noauth/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "module": "NodeNext",
4 | "moduleResolution": "NodeNext",
5 | "baseUrl": "src",
6 | "outDir": "./dist",
7 | "sourceMap": true,
8 | "noImplicitAny": true
9 | },
10 | "include": ["src/**/*"]
11 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "module": "NodeNext",
4 | "moduleResolution": "NodeNext",
5 | "target": "ES2020",
6 | "baseUrl": "src",
7 | "outDir": "./dist",
8 | "sourceMap": true,
9 | "noImplicitAny": true,
10 | },
11 | "include": ["src/**/*"],
12 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Auth/src/prisma/schema.prisma:
--------------------------------------------------------------------------------
1 | // This is your Prisma schema file,
2 | // learn more about it in the docs: https://pris.ly/d/prisma-schema
3 |
4 | generator client {
5 | provider = "prisma-client-js"
6 | }
7 |
8 | datasource db {
9 | provider = "mongodb"
10 | url = env("DATABASE_URL")
11 | }
12 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "module": "NodeNext",
4 | "moduleResolution": "NodeNext",
5 | "baseUrl": "src",
6 | "outDir": "./dist",
7 | "sourceMap": true,
8 | "noImplicitAny": true
9 | },
10 | "include": ["src/**/*"]
11 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "module": "NodeNext",
4 | "moduleResolution": "NodeNext",
5 | "target": "ES2020",
6 | "baseUrl": "src",
7 | "outDir": "./dist",
8 | "sourceMap": true,
9 | "noImplicitAny": true
10 | },
11 | "include": ["src/**/*"]
12 | }
13 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/src/models/model.ts:
--------------------------------------------------------------------------------
1 | import mongoose from "mongoose";
2 |
3 | interface typeName {
4 |
5 | }
6 |
7 | const { Schema, model } = mongoose;
8 |
9 | const schemaName = new Schema({
10 |
11 | });
12 |
13 | const modelName = model("modelName", schemaName);
14 |
15 | export default modelName;
--------------------------------------------------------------------------------
/yonode.org/theme/components/index.ts:
--------------------------------------------------------------------------------
1 | import { default as Button } from './button'
2 | import { default as CTA } from './cta'
3 | import { default as Features, Feature } from './features'
4 | import { default as SectionTitle } from './section-title'
5 | import { default as Section } from './section'
6 |
7 | export default { Button, CTA, Features, Feature, SectionTitle, Section }
8 |
--------------------------------------------------------------------------------
/yonode.org/theme/foundations/typography.ts:
--------------------------------------------------------------------------------
1 | export const fontSizes = {
2 | xs: '0.75rem',
3 | sm: '0.8125rem',
4 | md: '0.875rem',
5 | lg: '1',
6 | xl: '1.125rem',
7 | '2xl': '1.25rem',
8 | '3xl': '1.5rem',
9 | '4xl': '1.875rem',
10 | '5xl': '2',
11 | '6xl': '3.5rem',
12 | '7xl': '3rem',
13 | '8xl': '4rem',
14 | '9xl': '5rem',
15 | '10xl': '6rem',
16 | }
17 |
--------------------------------------------------------------------------------
/yonode.org/pages/api/hello.ts:
--------------------------------------------------------------------------------
1 | // Next.js API route support: https://nextjs.org/docs/api-routes/introduction
2 | import type { NextApiRequest, NextApiResponse } from 'next'
3 |
4 | type Data = {
5 | name: string
6 | }
7 |
8 | export default function handler(
9 | req: NextApiRequest,
10 | res: NextApiResponse
11 | ) {
12 | res.status(200).json({ name: 'John Doe' })
13 | }
14 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-NoAuth-Template/src/entity/entity.js:
--------------------------------------------------------------------------------
1 | import { EntitySchema } from "typeorm";
2 |
3 | const schemaName = new EntitySchema({
4 | name: "schemaName",
5 | tableName: "tableName",
6 | columns: {
7 | id: {
8 | primary: true,
9 | type: "int",
10 | generated: true,
11 | },
12 | },
13 | });
14 | export default schemaName;
15 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/src/entity/entity.js:
--------------------------------------------------------------------------------
1 | import { EntitySchema } from "typeorm";
2 |
3 | const schemaName = new EntitySchema({
4 | name: "schemaName",
5 | tableName: "tableName",
6 | columns: {
7 | id: {
8 | primary: true,
9 | type: "int",
10 | generated: true,
11 | },
12 | },
13 | });
14 | export default schemaName;
15 |
--------------------------------------------------------------------------------
/yonode.org/components/motion/page-transition.tsx:
--------------------------------------------------------------------------------
1 | import * as React from 'react'
2 | import { HTMLMotionProps } from 'framer-motion'
3 |
4 | import { MotionBox, MotionBoxProps } from './box'
5 |
6 | export const PageTransition: React.FC = (props) => (
7 |
12 | )
13 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-NoAuth-Template/src/entity/entity.js:
--------------------------------------------------------------------------------
1 | import { EntitySchema } from "typeorm";
2 |
3 | const SchemaName = new EntitySchema({
4 | name: "SchemaName",
5 | tableName: "tableName",
6 | columns: {
7 | _id: {
8 | primary: true,
9 | type: "mongodb-object-id",
10 | objectId: true,
11 | },
12 | },
13 | });
14 | export default SchemaName;
15 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/src/models/model.ts:
--------------------------------------------------------------------------------
1 | import { Model } from "sequelize";
2 | import sequelize from "../config/db.config";
3 |
4 | interface modelAttributes {
5 |
6 | }
7 |
8 | interface modelType extends Model , modelAttributes{}
9 |
10 | const modelName = sequelize.define("modelName",{
11 |
12 | })
13 |
14 | export default modelName;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-Auth-Template/src/config/initailConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL + process.env.DATABASE_NAME || "yonodeDB";
7 | export const jwtSecret = process.env.JWT_SECRET_KEY;
8 | export const nodeEnv = process.env.NODE_ENVIRONMENT || 'development';
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/prisma/client.js:
--------------------------------------------------------------------------------
1 | import { PrismaClient } from "@prisma/client";
2 |
3 | let prisma;
4 |
5 | if (process.env.NODE_ENV === "production") {
6 | prisma = new PrismaClient();
7 | } else {
8 | if (!globalThis.prisma) {
9 | globalThis.prisma = new PrismaClient();
10 | }
11 | prisma = globalThis.prisma;
12 | }
13 |
14 | export default prisma;
15 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/src/models/model.ts:
--------------------------------------------------------------------------------
1 | import { Model } from "sequelize";
2 | import sequelize from "../config/db.config";
3 |
4 | interface modelAttributes {
5 |
6 | }
7 |
8 | interface modelType extends Model, modelAttributes{};
9 |
10 | const modelName = sequelize.define("modelName",{
11 |
12 | })
13 |
14 | export default modelName;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-NoAuth-Template/prisma/client.js:
--------------------------------------------------------------------------------
1 | import { PrismaClient } from "@prisma/client";
2 |
3 | let prisma;
4 |
5 | if (process.env.NODE_ENV === "production") {
6 | prisma = new PrismaClient();
7 | } else {
8 |
9 | if (!globalThis.prisma) {
10 | globalThis.prisma = new PrismaClient();
11 | }
12 | prisma = globalThis.prisma;
13 | }
14 |
15 | export default prisma;
16 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-NoAuth-Template/prisma/client.js:
--------------------------------------------------------------------------------
1 | import { PrismaClient } from "@prisma/client";
2 |
3 | let prisma;
4 |
5 | if (process.env.NODE_ENV === "production") {
6 | prisma = new PrismaClient();
7 | } else {
8 |
9 | if (!globalThis.prisma) {
10 | globalThis.prisma = new PrismaClient();
11 | }
12 | prisma = globalThis.prisma;
13 | }
14 |
15 | export default prisma;
16 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-Auth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL + process.env.DATABASE_NAME || "yonodeDB";
7 | export const jwtSecret = process.env.JWT_SECRET_KEY;
8 | export const nodeEnv = process.env.NODE_ENVIRONMENT || 'development';
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-NoAuth-Template/prisma/client.js:
--------------------------------------------------------------------------------
1 | import { PrismaClient } from "@prisma/client";
2 |
3 | let prisma;
4 |
5 | if (process.env.NODE_ENV === "production") {
6 | prisma = new PrismaClient();
7 | } else {
8 |
9 | if (!globalThis.prisma) {
10 | globalThis.prisma = new PrismaClient();
11 | }
12 | prisma = globalThis.prisma;
13 | }
14 |
15 | export default prisma;
16 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-NoAuth-Template/prisma/schema.prisma:
--------------------------------------------------------------------------------
1 | // This is your Prisma schema file,
2 | // learn more about it in the docs: https://pris.ly/d/prisma-schema
3 |
4 | generator client {
5 | provider = "prisma-client-js"
6 | }
7 |
8 | datasource db {
9 | provider = "mysql"
10 | url = env("DATABASE_URL")
11 | }
12 |
13 | model modelName {
14 | id Int @id @default(autoincrement())
15 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-Auth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || 'yonodeDB';
8 | export const jwtSecret = process.env.JWT_SECRET_KEY;
9 | export const nodeEnv = process.env.NODE_ENVIRONMENT || 'development';
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-NoAuth-Template/prisma/schema.prisma:
--------------------------------------------------------------------------------
1 | // This is your Prisma schema file,
2 | // learn more about it in the docs: https://pris.ly/d/prisma-schema
3 |
4 | generator client {
5 | provider = "prisma-client-js"
6 | }
7 |
8 | datasource db {
9 | provider = "postgresql"
10 | url = env("DATABASE_URL")
11 | }
12 |
13 | model modelName {
14 | id Int @id @default(autoincrement())
15 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/TypeOrm/noAuth/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "module": "NodeNext",
4 | "moduleResolution": "NodeNext",
5 | "target": "ES2020",
6 | "baseUrl": "src",
7 | "outDir": "./dist",
8 | "sourceMap": true,
9 | "noImplicitAny": true,
10 | "emitDecoratorMetadata": true,
11 | "experimentalDecorators": true
12 | },
13 | "include": ["src/**/*"]
14 | }
15 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/src/app.ts:
--------------------------------------------------------------------------------
1 | // import the packages
2 | import express, { Express } from "express";
3 | import { port } from "config/initial.config";
4 |
5 | // initializing the app
6 | const app: Express = express();
7 | app.use(express.json());
8 |
9 | // rest of your code here
10 |
11 | app.listen(port, () => {
12 | console.log(`Server running on http://localhost:/${port}/`);
13 | });
14 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/noAuth/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "module": "NodeNext",
4 | "moduleResolution": "NodeNext",
5 | "target": "ES2020",
6 | "baseUrl": "src",
7 | "outDir": "./dist",
8 | "sourceMap": true,
9 | "noImplicitAny": true,
10 | "emitDecoratorMetadata": true,
11 | "experimentalDecorators": true
12 | },
13 | "include": ["src/**/*"]
14 | }
15 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/TypeOrm/noAuth/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "module": "NodeNext",
4 | "moduleResolution": "NodeNext",
5 | "target": "ES2020",
6 | "baseUrl": "src",
7 | "outDir": "./dist",
8 | "sourceMap": true,
9 | "noImplicitAny": true,
10 | "emitDecoratorMetadata": true,
11 | "experimentalDecorators": true
12 | },
13 | "include": ["src/**/*"]
14 | }
15 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-Auth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || "yonodeDB";
8 | export const jwtSecret = process.env.JWT_SECRET_KEY;
9 | export const nodeEnv = process.env.NODE_ENVIRONMENT || "development";
10 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-Auth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || "yonodeDB";
8 | export const jwtSecret = process.env.JWT_SECRET_KEY;
9 | export const nodeEnv = process.env.NODE_ENVIRONMENT || "development";
10 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/prisma/schema.prisma:
--------------------------------------------------------------------------------
1 | // This is your Prisma schema file,
2 | // learn more about it in the docs: https://pris.ly/d/prisma-schema
3 |
4 | generator client {
5 | provider = "prisma-client-js"
6 | }
7 |
8 | datasource db {
9 | provider = "postgresql"
10 | url = env("DATABASE_URL")
11 | }
12 |
13 | model User {
14 | id Int @id @default(autoincrement())
15 |
16 | }
17 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-Auth-Template/prisma/client.js:
--------------------------------------------------------------------------------
1 | import { PrismaClient } from "@prisma/client";
2 | import { nodeEnv } from "../src/config/initialConfig.js";
3 |
4 | let prisma;
5 |
6 | if (nodeEnv === "production") {
7 | prisma = new PrismaClient();
8 | } else {
9 | if (!globalThis.prisma) {
10 | globalThis.prisma = new PrismaClient();
11 | }
12 | prisma = globalThis.prisma;
13 | }
14 |
15 | export default prisma;
16 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-Auth-Template/prisma/client.js:
--------------------------------------------------------------------------------
1 | import { PrismaClient } from "@prisma/client";
2 | import { nodeEnv } from "../src/config/initailConfig.js";
3 |
4 | let prisma;
5 |
6 | if (nodeEnv === "production") {
7 | prisma = new PrismaClient();
8 | } else {
9 | if (!globalThis.prisma) {
10 | globalThis.prisma = new PrismaClient();
11 | }
12 | prisma = globalThis.prisma;
13 | }
14 |
15 | export default prisma;
16 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-Auth-Template/src/config/initialConfig.js:
--------------------------------------------------------------------------------
1 | import dotenv from "dotenv";
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.SERVER_PORT || 8000;
6 | export const dbUrl = process.env.DATABASE_URL;
7 | export const dbName = process.env.DATABASE_NAME || "yonodeDB";
8 | export const jwtSecret = process.env.JWT_SECRET_KEY;
9 | export const nodeEnv = process.env.NODE_ENVIRONMENT || "development";
10 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/app.js:
--------------------------------------------------------------------------------
1 | // import the packages
2 | import express from "express";
3 | import { port } from "config/initial.config";
4 | // import your files
5 | // initializing the app
6 | const app = express();
7 | app.use(express.json());
8 | // rest of your code here
9 | app.listen(port, () => {
10 | console.log(`Server running on http://localhost:/${port}/`);
11 | });
12 | //# sourceMappingURL=app.js.map
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-NoAuth-Template/prisma/schema.prisma:
--------------------------------------------------------------------------------
1 | // This is your Prisma schema file,
2 | // learn more about it in the docs: https://pris.ly/d/prisma-schema
3 |
4 | generator client {
5 | provider = "prisma-client-js"
6 | }
7 |
8 | datasource db {
9 | provider = "mongodb"
10 | url = env("DATABASE_URL")
11 | }
12 |
13 | model modelName {
14 | id String @id @default(auto()) @map("_id") @db.ObjectId
15 | }
16 |
17 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-Auth-Template/prisma/client.js:
--------------------------------------------------------------------------------
1 | import { PrismaClient } from "@prisma/client";
2 | import { nodeEnv } from "../src/config/initialConfig.js";
3 |
4 | let prisma;
5 |
6 | if (nodeEnv === "production") {
7 | prisma = new PrismaClient();
8 | } else {
9 | if (!globalThis.prisma) {
10 | globalThis.prisma = new PrismaClient();
11 | }
12 | prisma = globalThis.prisma;
13 | }
14 |
15 | export default prisma;
16 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Auth/src/app.js:
--------------------------------------------------------------------------------
1 | // import the packages
2 | import express from 'express';
3 | import { port } from './config/initial.config.js';
4 | import chalk from 'chalk'
5 | // Initializing app
6 | const app = express();
7 | const PORT = port;
8 |
9 | // rest of your code here
10 |
11 |
12 |
13 | app.listen(PORT, () => {
14 | console.log(`${chalk.blue.bold('Server')} is listening on port ${PORT} 🚀`);
15 | });
16 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/prisma/schema.prisma:
--------------------------------------------------------------------------------
1 | // This is your Prisma schema file,
2 | // learn more about it in the docs: https://pris.ly/d/prisma-schema
3 |
4 | generator client {
5 | provider = "prisma-client-js"
6 | }
7 |
8 | datasource db {
9 | provider = "mongodb"
10 | url = env("DATABASE_URL")
11 | }
12 |
13 | model User {
14 | id String @id @default(auto()) @map("_id") @db.ObjectId
15 |
16 | }
17 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/Auth/src/routes/user.router.js:
--------------------------------------------------------------------------------
1 | import express from "express";
2 | import { registerUser } from "../controllers/user.controller.js";
3 |
4 | const userRouter = express.Router();
5 |
6 | userRouter.post('/register-user', registerUser);
7 | // userRouter.get('/verify-user', verifyUser);
8 | // userRouter.post('/login-user', loginUser);
9 | // userRouter.post('/logout-user', logoutUser);
10 |
11 | export default userRouter;
--------------------------------------------------------------------------------
/yonode.org/theme/components/section.ts:
--------------------------------------------------------------------------------
1 | const Section = {
2 | baseStyle: {
3 | pt: 28,
4 | pb: 28,
5 | px: [4, null],
6 | },
7 | variants: {
8 | subtle: {},
9 | solid: {
10 | bg: 'primary.400',
11 | },
12 | alternate: ({ colorMode }: any) => ({
13 | bg: colorMode === 'dark' ? 'gray.800' : 'gray.50',
14 | }),
15 | },
16 | defaultProps: {
17 | variant: 'subtle',
18 | },
19 | }
20 |
21 | export default Section
22 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/prisma/Noauth/src/app.ts:
--------------------------------------------------------------------------------
1 | // import the packages
2 | import express, { Express } from "express";
3 |
4 | // import your files
5 | import { port } from "./config/initial.config";
6 |
7 |
8 | // Initializing the app
9 | const app: Express = express();
10 | app.use(express.json());
11 |
12 | // rest of your code here
13 |
14 |
15 | app.listen(port, () => {
16 | console.log(`Server running on http://localhost:/${port}`);
17 | });
18 |
--------------------------------------------------------------------------------
/packages/yonode/src/lib/programOptions.js:
--------------------------------------------------------------------------------
1 | import { program } from 'commander'
2 |
3 | import { readFile } from 'fs/promises';
4 | const pkg = JSON.parse(await readFile(new URL('../../package.json', import.meta.url)));
5 |
6 | program
7 | .option('-v, --version', 'output the version number')
8 |
9 | program.parse(process.argv);
10 |
11 | const options = program.opts();
12 |
13 | if (options.version) {
14 | console.log(pkg.version);
15 | process.exit(1)
16 | }
17 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # TypeScript cache
9 | *.tsbuildinfo
10 |
11 | # Optional cache directories
12 | .eslintcache
13 | .stylelintcache
14 |
15 | # Environment variables
16 | .env
17 | .env.development.local
18 | .env.test.local
19 | .env.production.local
20 | .env.local
21 |
22 | # Yarn and npm cache
23 | .npm/
24 |
25 | # Miscellaneous
26 | .node_repl_history
27 | .vscode-test
28 |
--------------------------------------------------------------------------------
/yonode.org/components/button-link/button-link.tsx:
--------------------------------------------------------------------------------
1 | import { Button, ButtonProps } from '@chakra-ui/react'
2 | import NextLink, { LinkProps } from 'next/link'
3 |
4 | export type ButtonLinkProps = LinkProps & ButtonProps
5 |
6 | export const ButtonLink: React.FC = ({
7 | href,
8 | children,
9 | ...props
10 | }) => {
11 | return (
12 |
13 |
14 |
15 | )
16 | }
17 |
--------------------------------------------------------------------------------
/SECURITY.md:
--------------------------------------------------------------------------------
1 | Reporting a Vulnerability
2 |
3 | If you believe you have found a security vulnerability in Yonode, please report it to us responsibly. Do not open a public issue. We will investigate all legitimate reports. Send your report to [security@yonode.org](mailto:security@yonode.org).
4 |
5 | While the discovery of new vulnerabilities is rare, we also recommend always using the latest versions of Yonode and its official plugins to ensure your application remains as secure as possible.
6 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/src/app.ts:
--------------------------------------------------------------------------------
1 | // import the packages
2 | import express, { Express } from "express";
3 | import { port } from "config/initial.config";
4 |
5 | // import your files
6 |
7 |
8 | // initializing the app
9 | const app: Express = express();
10 | app.use(express.json());
11 |
12 | // rest of your code here
13 |
14 |
15 |
16 |
17 | app.listen(port, () => {
18 | console.log(`Server running on http://localhost:/${port}/`);
19 | });
20 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Noauth/dist/app.js.map:
--------------------------------------------------------------------------------
1 | {"version":3,"file":"app.js","sourceRoot":"","sources":["../src/app.ts"],"names":[],"mappings":"AAAA,sBAAsB;AACtB,OAAO,OAAoB,MAAM,SAAS,CAAC;AAC3C,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAE7C,oBAAoB;AAGpB,uBAAuB;AACvB,MAAM,GAAG,GAAY,OAAO,EAAE,CAAC;AAC/B,GAAG,CAAC,GAAG,CAAC,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC;AAExB,yBAAyB;AAKzB,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE,GAAG,EAAE;IACpB,OAAO,CAAC,GAAG,CAAC,uCAAuC,IAAI,GAAG,CAAC,CAAC;AAC9D,CAAC,CAAC,CAAC"}
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/TypeOrm/noAuth/src/app.ts:
--------------------------------------------------------------------------------
1 | // import the packages
2 | import express, { Express } from "express";
3 |
4 | // import your files
5 | import { port } from "./config/initial.config";
6 | import "./config/db.config";
7 |
8 | // initializing the app
9 | const app: Express = express();
10 | app.use(express.json());
11 |
12 | // rest of your code here
13 |
14 |
15 | app.listen(port, () => {
16 | console.log(`Server running on http://localhost:/${port}/`);
17 | });
18 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/src/controllers/helloWorldController.js:
--------------------------------------------------------------------------------
1 |
2 | export const helloWorld = async (req, res) => {
3 | try {
4 | // Send a simple string as a response
5 | res.send("Hello World!")
6 | } catch (err) {
7 | // If there's an error, send a response with a 500 status code
8 | // and an error message
9 | res.status(500).json({
10 | message: "Internal Server Error"
11 | })
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/noAuth/src/app.ts:
--------------------------------------------------------------------------------
1 | // import the packages
2 | import express, { Express } from "express";
3 |
4 | // import your files
5 | import { port } from "./config/initial.config";
6 | import "./config/db.config";
7 |
8 | // initializing the app
9 | const app: Express = express();
10 | app.use(express.json());
11 |
12 | // rest of your code here
13 |
14 |
15 | app.listen(port, () => {
16 | console.log(`Server running on http://localhost:/${port}/`);
17 | });
18 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/TypeOrm/noAuth/src/app.ts:
--------------------------------------------------------------------------------
1 | // import the packages
2 | import express, { Express } from "express";
3 |
4 | // import your files
5 | import { port } from "./config/initial.config";
6 | import "./config/db.config";
7 |
8 | // initializing the app
9 | const app: Express = express();
10 | app.use(express.json());
11 |
12 | // rest of your code here
13 |
14 |
15 | app.listen(port, () => {
16 | console.log(`Server running on http://localhost:/${port}/`);
17 | });
18 |
--------------------------------------------------------------------------------
/.eslintrc.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | extends: [
3 | "some-other-config-you-use",
4 | "plugin:prettier/recommended" // Enables eslint-plugin-prettier and eslint-config-prettier
5 | ],
6 | plugins: [
7 | "prettier" // Adds the plugin that integrates Prettier with ESLint
8 | ],
9 | rules: {
10 | "prettier/prettier": "error", // Indicates any deviations from Prettier formatting as ESLint errors
11 | // You can override/add specific rules settings here
12 | }
13 | };
14 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/src/config/db.config.ts:
--------------------------------------------------------------------------------
1 | import mongoose from "mongoose";
2 | import { dbName, dbUrl } from "./initial.config";
3 |
4 | const connectDB = async (): Promise => {
5 | try {
6 | await mongoose.connect(dbUrl, {
7 | dbName,
8 | });
9 | console.log("Connected to the database");
10 | } catch (error) {
11 | console.error("Error connecting to database", error);
12 | process.exit(1);
13 | }
14 | };
15 |
16 | export default connectDB;
17 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-Auth-Template/src/entity/User.js:
--------------------------------------------------------------------------------
1 | import { EntitySchema } from "typeorm";
2 |
3 | const User = new EntitySchema({
4 | name: "User",
5 | tableName: "users",
6 | columns: {
7 | _id: {
8 | primary: true,
9 | type: "int",
10 | generated: true,
11 | },
12 | email: {
13 | type: "varchar",
14 | unique: true,
15 | },
16 | password: {
17 | type: "varchar",
18 | required: true,
19 | },
20 | },
21 | });
22 | export default User;
23 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-Auth-Template/src/entity/User.js:
--------------------------------------------------------------------------------
1 | import { EntitySchema } from "typeorm";
2 |
3 | const User = new EntitySchema({
4 | name: "User",
5 | tableName: "users",
6 | columns: {
7 | _id: {
8 | primary: true,
9 | type: "int",
10 | generated: true,
11 | },
12 | email: {
13 | type: "varchar",
14 | unique: true,
15 | },
16 | password: {
17 | type: "varchar",
18 | required: true,
19 | },
20 | },
21 | });
22 | export default User;
23 |
--------------------------------------------------------------------------------
/packages/yonode/src/lib/prompt/auth.js:
--------------------------------------------------------------------------------
1 | import inquirer from "inquirer";
2 | import { options } from "../../index.js";
3 | import { authQuestion } from "../questions.js";
4 | import { repoConditions } from "../repoConditions.js";
5 |
6 | export const authType = () => {
7 | inquirer
8 | .prompt(authQuestion)
9 | .then((answer) => {
10 | options.auth = answer.auth_type;
11 | repoConditions()
12 | })
13 | .catch((error) => {
14 | if (error.isTtyError) {
15 | } else {
16 | }
17 | });
18 | };
19 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-Auth-Template/src/entity/User.js:
--------------------------------------------------------------------------------
1 | import { EntitySchema } from "typeorm";
2 |
3 | const User = new EntitySchema({
4 | name: "User",
5 | tableName: "users",
6 | columns: {
7 | _id: {
8 | primary: true,
9 | type: "mongodb-object-id",
10 | objectId: true,
11 | },
12 | email: {
13 | type: "string",
14 | unique: true,
15 | },
16 | password: {
17 | type: "string",
18 | required: true,
19 | },
20 | },
21 | });
22 | export default User;
23 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/Auth/src/config/initial.config.js:
--------------------------------------------------------------------------------
1 | import dotenv from 'dotenv';
2 |
3 | dotenv.config();
4 |
5 | export const port = process.env.PORT || 8000;
6 | export const dbURL = process.env.DATABASE_URL;
7 | export const JWT_Secret = process.env.JWT_SECRET_KEY;
8 | export const Web_Url = process.env.WEB_URL
9 |
10 | // email
11 | export const emailService = process.env.SERVICE
12 | export const emailUser = process.env.USER
13 | export const emailPass = process.env.PASS
14 | export const emailFrom = process.env.FROM
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-Auth-Template/src/routes/authRoutes.js:
--------------------------------------------------------------------------------
1 | import express from 'express';
2 | import { validateUserLogin, validateUserRegister } from '../middlewares/validators/authValidator.js';
3 | import { loginUser, registerUser } from '../controllers/authController.js';
4 |
5 | const router = express.Router();
6 |
7 | // Validate registration input
8 | router.post('/register',validateUserRegister, registerUser);
9 |
10 | // Validate login input
11 | router.post('/login', validateUserLogin,loginUser);
12 |
13 | export default router;
14 |
--------------------------------------------------------------------------------
/yonode.org/components/layout/theme-toggle.tsx:
--------------------------------------------------------------------------------
1 | import { IconButton, useColorMode } from '@chakra-ui/react'
2 | import { FiMoon, FiSun } from 'react-icons/fi'
3 |
4 | const ThemeToggle = () => {
5 | const { colorMode, toggleColorMode } = useColorMode()
6 | return (
7 | : }
11 | borderRadius="md"
12 | onClick={toggleColorMode}
13 | />
14 | )
15 | }
16 |
17 | export default ThemeToggle
18 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-Auth-Template/src/routes/authRoutes.js:
--------------------------------------------------------------------------------
1 | import express from 'express';
2 | import { validateUserLogin, validateUserRegister } from '../middlewares/validators/authValidator.js';
3 | import { loginUser, registerUser } from '../controllers/authController.js';
4 |
5 | const router = express.Router();
6 |
7 | // Validate registration input
8 | router.post('/register',validateUserRegister, registerUser);
9 |
10 | // Validate login input
11 | router.post('/login', validateUserLogin,loginUser);
12 |
13 | export default router;
14 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/src/app.ts:
--------------------------------------------------------------------------------
1 | // import the packages
2 | import express, { Express } from "express";
3 |
4 | // import your files
5 | import { port } from "./config/initial.config";
6 | import connectDB from './config/db.config';
7 |
8 | // initializing the app
9 | const app: Express = express();
10 | app.use(express.json());
11 |
12 | // rest of your code here
13 |
14 |
15 | // database connection
16 | connectDB();
17 |
18 | app.listen(port, () => {
19 | console.log(`Server running on http://localhost:/${port}/`);
20 | });
21 |
--------------------------------------------------------------------------------
/renovate.json5:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://docs.renovatebot.com/renovate-schema.json",
3 | "extends": [
4 | "config:base",
5 | "schedule:weekly",
6 | "group:allNonMajor"
7 | ],
8 | "labels": [
9 | "dependencies"
10 | ],
11 | "ignorePaths": [
12 | "**/typescript/**",
13 | "**/node_modules/**",
14 | "**/__tests__/**",
15 | "**/__mocks__/**",
16 | "**/dist/**",
17 | "**/coverage/**",
18 | "/yonode.org/**",
19 | "/docs.yonode.org/**"
20 | ],
21 | "rangeStrategy": "bump",
22 | "reviewers": ["isasharafdin"]
23 | }
24 |
--------------------------------------------------------------------------------
/yonode.org/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | .vscode
4 |
5 | # dependencies
6 | /node_modules
7 | /.pnp
8 | .pnp.js
9 |
10 | # testing
11 | /coverage
12 |
13 | # next.js
14 | /.next/
15 | /out/
16 |
17 | # production
18 | /build
19 |
20 | # misc
21 | .DS_Store
22 | *.pem
23 |
24 | # debug
25 | npm-debug.log*
26 | yarn-debug.log*
27 | yarn-error.log*
28 | .pnpm-debug.log*
29 |
30 | # local env files
31 | .env*.local
32 |
33 | # vercel
34 | .vercel
35 |
36 | # typescript
37 | *.tsbuildinfo
38 |
39 | .contentlayer
--------------------------------------------------------------------------------
/yonode.org/components/seo/seo.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import { NextSeo, NextSeoProps } from 'next-seo'
3 | import siteConfig from 'data/config'
4 |
5 | export interface SEOProps extends NextSeoProps {}
6 |
7 | export const SEO = ({ title, description, ...props }: SEOProps) => (
8 |
16 | )
17 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/src/app.ts:
--------------------------------------------------------------------------------
1 | // import the packages
2 | import express, { Express } from "express";
3 |
4 | // import your files
5 | import { port } from "./config/initial.config";
6 | import { connectDB } from "./config/db.config";
7 | import "./models/models"
8 |
9 | // initializing the app
10 | const app: Express = express();
11 | app.use(express.json());
12 |
13 | // rest of your code here
14 |
15 | // database connection
16 | connectDB();
17 |
18 | app.listen(port, () => {
19 | console.log(`Server running on http://localhost:/${port}`);
20 | });
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/src/app.ts:
--------------------------------------------------------------------------------
1 | // import packages
2 | import express, { Express } from 'express';
3 |
4 | // import files
5 | import { port } from './config/initial.config';
6 | import { connectDB } from './config/db.config';
7 | import "./models/models"
8 |
9 |
10 | // Initialize app
11 | const app: Express = express();
12 | app.use(express.json());
13 |
14 | // // rest of your code here
15 |
16 | // database connection
17 | connectDB();
18 |
19 | app.listen(port, () => {
20 | console.log(`Server running on http://localhost:/${port}`);
21 | });
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/prisma/Noauth/prisma/schema.prisma:
--------------------------------------------------------------------------------
1 | // This is your Prisma schema file,
2 | // learn more about it in the docs: https://pris.ly/d/prisma-schema
3 |
4 | // Looking for ways to speed up your queries, or scale easily with your serverless or edge functions?
5 | // Try Prisma Accelerate: https://pris.ly/cli/accelerate-init
6 |
7 | generator client {
8 | provider = "prisma-client-js"
9 | }
10 |
11 | datasource db {
12 | provider = "mysql"
13 | url = env("DATABASE_URL")
14 | }
15 |
16 | model modelName {
17 | id Int @id @default(autoincrement())
18 | }
--------------------------------------------------------------------------------
/yonode.org/hooks/use-route-changed.ts:
--------------------------------------------------------------------------------
1 | import { useRouter } from 'next/router'
2 | import { useEffect } from 'react'
3 |
4 | const useRouteChanged = (fn: () => void) => {
5 | const router = useRouter()
6 | useEffect(() => {
7 | const handleRouteChange = (url: string) => {
8 | fn()
9 | console.log('App is changing to: ', url)
10 | }
11 |
12 | router.events.on('routeChangeComplete', handleRouteChange)
13 |
14 | return () => {
15 | router.events.off('routeChangeComplete', handleRouteChange)
16 | }
17 | }, [router.events, fn])
18 | }
19 |
20 | export default useRouteChanged
21 |
--------------------------------------------------------------------------------
/docs.yonode.org/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "es5",
4 | "lib": ["dom", "dom.iterable", "esnext"],
5 | "allowJs": true,
6 | "skipLibCheck": true,
7 | "strict": false,
8 | "forceConsistentCasingInFileNames": true,
9 | "noEmit": true,
10 | "incremental": true,
11 | "esModuleInterop": true,
12 | "module": "esnext",
13 | "moduleResolution": "node",
14 | "resolveJsonModule": true,
15 | "isolatedModules": true,
16 | "jsx": "preserve"
17 | },
18 | "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"],
19 | "exclude": ["node_modules"]
20 | }
21 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/TypeOrm/noAuth/src/config/db.config.ts:
--------------------------------------------------------------------------------
1 | import "reflect-metadata";
2 | import { DataSource } from "typeorm";
3 | import { EntityName } from "../entity/Entity";
4 | import { dbName, dbUrl } from "./initial.config";
5 |
6 | const AppDataSource = new DataSource({
7 | type: "mysql",
8 | url: dbUrl,
9 | database: dbName,
10 | entities: [EntityName],
11 | });
12 | AppDataSource.initialize()
13 | .then(async () => {
14 | console.log(`Connected to the database`);
15 | })
16 | .catch((error) => console.error("Error connecting to database", error));
17 | export default AppDataSource;
18 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/noAuth/src/config/db.config.ts:
--------------------------------------------------------------------------------
1 | import "reflect-metadata";
2 | import { DataSource } from "typeorm";
3 | import { EntityName } from "../entity/Entity";
4 | import { dbName, dbUrl } from "./initial.config";
5 |
6 | const AppDataSource = new DataSource({
7 | type: "mongodb",
8 | url: dbUrl,
9 | database: dbName,
10 | entities: [EntityName],
11 | });
12 | AppDataSource.initialize()
13 | .then(async () => {
14 | console.log(`connected to the database`);
15 | })
16 | .catch((error) => console.error("Error connecting to database", error));
17 | export default AppDataSource;
18 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/TypeOrm/noAuth/src/config/db.config.ts:
--------------------------------------------------------------------------------
1 | import "reflect-metadata";
2 | import { DataSource } from "typeorm";
3 | import { EntityName } from "../entity/Entity";
4 | import { dbName, dbUrl } from "./initial.config";
5 |
6 | const AppDataSource = new DataSource({
7 | type: "postgres",
8 | url: dbUrl,
9 | database: dbName,
10 | entities: [EntityName],
11 | });
12 | AppDataSource.initialize()
13 | .then(async () => {
14 | console.log(`Connected to the database`);
15 | })
16 | .catch((error) => console.error("Error connecting to database", error));
17 | export default AppDataSource;
18 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-Auth-Template/src/models/User.js:
--------------------------------------------------------------------------------
1 | import sequelize from '../config/dbConfig.js';
2 | import { DataTypes } from 'sequelize';
3 |
4 | // Define a schema for the user with email and password fields
5 | const User = sequelize.define('User', {
6 | email:{
7 | type: DataTypes.STRING,
8 | allowNull: false, // Makes this field mandatory
9 | unique: true, // // Ensures email addresses are unique in the database
10 | },
11 | password: {
12 | type: DataTypes.STRING,
13 | allowNull: false, // Makes this field mandatory
14 | }
15 | })
16 |
17 | export default User;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/src/config/db.config.ts:
--------------------------------------------------------------------------------
1 | import { Sequelize } from "sequelize";
2 | import { dbUrl } from "./initial.config";
3 |
4 | const sequelize = new Sequelize(dbUrl);
5 |
6 | export const connectDB = async (): Promise => {
7 | try {
8 | await sequelize.authenticate();
9 | console.log("Connected to the database");
10 | await sequelize.sync();
11 | console.log("Model synced successfully");
12 | } catch (error) {
13 | console.error("Error connecting to database", error);
14 | process.exit(1);
15 | }
16 | }
17 |
18 | export default sequelize;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-Auth-Template/src/models/User.js:
--------------------------------------------------------------------------------
1 | import sequelize from '../config/dbConfig.js';
2 | import { DataTypes } from 'sequelize';
3 |
4 | // Define a schema for the user with email and password fields
5 | const User = sequelize.define('User', {
6 | email:{
7 | type: DataTypes.STRING,
8 | allowNull: false, // Makes this field mandatory
9 | unique: true, // // Ensures email addresses are unique in the database
10 | },
11 | password: {
12 | type: DataTypes.STRING,
13 | allowNull: false, // Makes this field mandatory
14 | }
15 | })
16 |
17 | export default User;
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/src/config/db.config.ts:
--------------------------------------------------------------------------------
1 | import { Sequelize } from "sequelize";
2 | import { dbUrl } from "./initial.config";
3 |
4 | const sequelize = new Sequelize(dbUrl);
5 |
6 | export const connectDB = async (): Promise => {
7 | try {
8 | await sequelize.authenticate();
9 | console.log("Connected to the database");
10 | await sequelize.sync();
11 | console.log("Model synced successfully");
12 | } catch (error) {
13 | console.error("Error connecting to database", error);
14 | process.exit(1);
15 | }
16 | }
17 |
18 | export default sequelize;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-NoAuth-Template/src/controllers/helloWorldController.js:
--------------------------------------------------------------------------------
1 | /**
2 | * A simple controller function to handle requests to the '/' route
3 | * @param {object} req The request object
4 | * @param {object} res The response object
5 | * @returns {object} The response object
6 | */
7 | export const helloWorld = async (req, res) => {
8 | try {
9 | // Send a response to the client
10 | res.send("Hello world!");
11 | } catch (err) {
12 | // If there is an error, send a 500 error with a JSON response
13 | res.status(500).json({
14 | message: "Internal Server Error",
15 | });
16 | }
17 | };
18 |
19 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-Auth-Template/prisma/schema.prisma:
--------------------------------------------------------------------------------
1 | // This is your Prisma schema file,
2 | // learn more about it in the docs: https://pris.ly/d/prisma-schema
3 |
4 | // Looking for ways to speed up your queries, or scale easily with your serverless or edge functions?
5 | // Try Prisma Accelerate: https://pris.ly/cli/accelerate-init
6 |
7 | generator client {
8 | provider = "prisma-client-js"
9 | }
10 |
11 | datasource db {
12 | provider = "mysql"
13 | url = env("DATABASE_URL")
14 | }
15 |
16 | model User {
17 | id Int @id @default(autoincrement())
18 | email String @unique
19 | password String
20 | }
21 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-Auth-Template/prisma/schema.prisma:
--------------------------------------------------------------------------------
1 | // This is your Prisma schema file,
2 | // learn more about it in the docs: https://pris.ly/d/prisma-schema
3 |
4 | // Looking for ways to speed up your queries, or scale easily with your serverless or edge functions?
5 | // Try Prisma Accelerate: https://pris.ly/cli/accelerate-init
6 |
7 | generator client {
8 | provider = "prisma-client-js"
9 | }
10 |
11 | datasource db {
12 | provider = "postgresql"
13 | url = env("DATABASE_URL")
14 | }
15 |
16 | model User{
17 | id Int @id @default(autoincrement())
18 | email String @unique
19 | password String
20 |
21 | }
22 |
23 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/Auth/src/config/db.config.js:
--------------------------------------------------------------------------------
1 | import "reflect-metadata";
2 | import { DataSource } from "typeorm";
3 | import { dbURL } from "./initial.config.js";
4 | import chalk from "chalk";
5 | import User from "../entity/User.entity.js";
6 |
7 | const AppDataSource = new DataSource({
8 | type: "mongodb",
9 | url: dbURL,
10 | database: "yonode",
11 | entities: [User],
12 | synchronize: true,
13 | });
14 | AppDataSource.initialize()
15 | .then(async () => {
16 | console.log(`${chalk.green.bold("Connected")} to the database ✅`);
17 | })
18 | .catch((error) => console.log(error));
19 | export default AppDataSource;
20 |
--------------------------------------------------------------------------------
/yonode.org/components/motion/fall-in-place.tsx:
--------------------------------------------------------------------------------
1 | import { MotionBox, MotionBoxProps } from './box'
2 | import React from 'react'
3 |
4 | export const FallInPlace: React.FC = (
5 | props
6 | ) => {
7 | const { children, delay = 0.2, ...rest } = props
8 | return (
9 |
20 | {children}
21 |
22 | )
23 | }
24 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-Auth-Template/prisma/schema.prisma:
--------------------------------------------------------------------------------
1 | // This is your Prisma schema file,
2 | // learn more about it in the docs: https://pris.ly/d/prisma-schema
3 |
4 | // Looking for ways to speed up your queries, or scale easily with your serverless or edge functions?
5 | // Try Prisma Accelerate: https://pris.ly/cli/accelerate-init
6 |
7 | generator client {
8 | provider = "prisma-client-js"
9 | }
10 |
11 | datasource db {
12 | provider = "mongodb"
13 | url = env("DATABASE_URL")
14 | }
15 |
16 | model User {
17 | id String @id @default(auto()) @map("_id") @db.ObjectId
18 | email String @unique
19 | password String
20 | }
21 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-Auth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | import chalk from "chalk";
2 | import { Sequelize } from "sequelize";
3 | import { dbUrl } from "./initailConfig.js";
4 |
5 | const sequelize = new Sequelize(dbUrl);
6 |
7 | export const connectDB = async () => {
8 | try {
9 | await sequelize.authenticate();
10 | console.log(`${chalk.green.bold("Connected")} to the database`);
11 | await sequelize.sync();
12 | console.log(`${chalk.green.bold("Models synced")} successfully`);
13 | } catch (error) {
14 | console.log(`${chalk.red.bold("Error")} connecting to database `, error);
15 | }
16 | };
17 |
18 | export default sequelize;
19 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Prisma/Auth/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "yonode-api-starter",
3 | "version": "1.0.0",
4 | "type": "module",
5 | "main": "./src/app.js",
6 | "license": "MIT",
7 | "scripts": {
8 | "start": "node ./src/app.js",
9 | "dev": "nodemon ./src/app.js"
10 | },
11 | "dependencies": {
12 | "bcrypt": "^5.1.1",
13 | "body-parser": "^1.20.2",
14 | "chalk": "^5.3.0",
15 | "cors": "^2.8.5",
16 | "dotenv": "^16.4.1",
17 | "express": "^4.18.2",
18 | "helmet": "^7.1.0",
19 | "morgan": "^1.10.0",
20 | "nodemon": "^3.0.3"
21 | },
22 | "devDependencies": {
23 | "prisma": "^5.9.1"
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-Auth-Template/src/models/User.js:
--------------------------------------------------------------------------------
1 | // Import required modules and configuration
2 | import mongoose from "mongoose";
3 |
4 | // Define a schema for the user with email and password fields
5 | const UserSchema = new mongoose.Schema({
6 | email: {
7 | type: String,
8 | required: true, // Makes this field mandatory
9 | unique: true, // Ensures email addresses are unique in the database
10 | },
11 | password: {
12 | type: String,
13 | required: true, // Makes this field mandatory
14 | },
15 | });
16 |
17 | // Create and export the User model
18 | const User = mongoose.model("User", UserSchema);
19 | export default User;
20 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-Auth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MySQL with Prisma
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-NoAuth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MySQL with Prisma
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-Auth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MYSQL with Sequelize
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-Auth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MySQL with TypeORM
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-NoAuth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | import "reflect-metadata";
2 | import { DataSource } from "typeorm";
3 | import { dbName, dbUrl } from "./initialConfig.js";
4 | import chalk from "chalk";
5 |
6 | const AppDataSource = new DataSource({
7 | type: "mysql",
8 | url: dbUrl,
9 | database: dbName,
10 | entities: ["../entity/*/.js"],
11 | });
12 |
13 | AppDataSource.initialize()
14 | .then(async () => {
15 | console.log(`${chalk.green.bold('Connected')} to the database`);
16 | })
17 | .catch((error) =>
18 | console.log(`${chalk.red.bold('Error')} connecting to database`, error)
19 | );
20 |
21 | export default AppDataSource;
22 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-Auth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MongoDB with Prisma
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-NoAuth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MongoDB with Prisma
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-Auth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MongoDB with TypeORM
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-NoAuth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MySQL with TypeORM
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/yonode.org/components/typography/index.tsx:
--------------------------------------------------------------------------------
1 | import {
2 | chakra,
3 | HTMLChakraProps,
4 | Text,
5 | TextProps,
6 | useColorModeValue,
7 | } from '@chakra-ui/react'
8 |
9 | export const Em: React.FC> = ({ children, ...props }) => {
10 | return (
11 |
17 | {children}
18 |
19 | )
20 | }
21 |
22 | // @todo make this configurable
23 | export const Br: React.FC> = (props) => {
24 | return (
25 |
26 |
27 |
28 | )
29 | }
30 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-Auth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MongoDB with Mongoose
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MongoDB with Mongoose
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-NoAuth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MongoDB with TypeORM
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + MySQL with Sequelize
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-NoAuth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + PostgreSQL with Prisma
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-Auth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + PostgreSQL with TypeORM
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | import "reflect-metadata";
2 | import { DataSource } from "typeorm";
3 | import { dbName, dbUrl } from "./initialConfig.js";
4 | import chalk from "chalk";
5 |
6 | const AppDataSource = new DataSource({
7 | type: "postgres",
8 | url: dbUrl,
9 | database: dbName,
10 | entities: ["../entity/*/.js"],
11 | });
12 |
13 | AppDataSource.initialize()
14 | .then(async () => {
15 | console.log(`${chalk.green.bold('Connected')} to the database`);
16 | })
17 | .catch((error) =>
18 | console.log(`${chalk.red.bold('Error')} connecting to database`, error)
19 | );
20 |
21 | export default AppDataSource;
22 |
--------------------------------------------------------------------------------
/yonode.org/theme/components/button.ts:
--------------------------------------------------------------------------------
1 | import { mode } from '@chakra-ui/theme-tools'
2 |
3 | type Dict = Record
4 |
5 | export default {
6 | variants: {
7 | 'nav-link': (props: Dict) => {
8 | const { isActive } = props
9 |
10 | const hoverColor = mode('gray.900', 'white')(props)
11 | return {
12 | outline: 'none',
13 | fontWeight: '500',
14 | color: isActive
15 | ? hoverColor
16 | : mode('gray.700', 'whiteAlpha.700')(props),
17 | transition: 'color .2s ease-in',
18 | _hover: {
19 | textDecoration: 'none',
20 | color: hoverColor,
21 | },
22 | }
23 | },
24 | },
25 | }
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-Auth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + PostgreSQL with Sequelize
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + PostgreSQL with TypeORM
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 | The server is running and ready to serve requests.
21 |
22 | Now, Go to the Src directory and start building the server.
23 |
24 | Happy coding!
25 |
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/TypeOrm/noAuth/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + TypeScript + MySQL with TypeOrm
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/prisma/Noauth/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + TypeScript + Mysql with Prisma
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + PostgreSQL with Sequelize
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 | The server is running and ready to serve requests.
21 |
22 | Now, Go to the Src directory and start building the server.
23 |
24 | Happy coding!
25 |
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/TypeORM/noAuth/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + TypeScript + MongoDB with TypeORM
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MySQL/Sequelize/NoAuth/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + TypeScript + Mysql with Sequelize
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/MongoDB/Mongoose/NoAuth/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + TypeScript + MongoDB with Mongoose
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Prisma/Noauth/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + TypeScript + PostgreSQL with Prisma
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/TypeOrm/noAuth/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + TypeScript + PostgreSQL with TypeOrm
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/typescript/PostgreSQL/Sequelize/NoAuth/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + TypeScript + Postgresql with Sequelize
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
--------------------------------------------------------------------------------
/yonode.org/components/motion/float.tsx:
--------------------------------------------------------------------------------
1 | import { MotionBox, MotionBoxProps } from './box'
2 | import React from 'react'
3 |
4 | export const Float: React.FC<
5 | MotionBoxProps & { delay?: number; steps?: number[] }
6 | > = (props) => {
7 | const { children, delay = 0.2, steps = [10, -10, 10], ...rest } = props
8 | return (
9 |
22 | {children}
23 |
24 | )
25 | }
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | import chalk from "chalk";
2 | import { Sequelize } from "sequelize"
3 | import { dbUrl } from "./initialConfig.js";
4 |
5 | export const sequelize = new Sequelize(dbUrl);
6 | export const connectDB = async () => {
7 | try {
8 | await sequelize.authenticate();
9 | console.log(`${chalk.green.bold('Connected')} to the database`);
10 | await sequelize.sync();
11 | console.log(`${chalk.green.bold('Models synced')} successfully`);
12 | } catch (error) {
13 | console.log(`${chalk.red.bold('Error')} connecting to database`, error);
14 | process.exit(1);
15 | }
16 | }
17 |
18 | export default sequelize;
19 |
--------------------------------------------------------------------------------
/yonode.org/pages/_app.tsx:
--------------------------------------------------------------------------------
1 | import type { AppProps } from 'next/app'
2 |
3 | import { AuthProvider, SaasProvider } from '@saas-ui/react'
4 | import { Layout } from 'components/layout'
5 |
6 | import theme from '../theme'
7 |
8 | function MyApp({ Component, pageProps }: AppProps) {
9 | const { announcement, header, footer } = pageProps
10 |
11 | return (
12 |
13 |
14 |
19 |
20 |
21 |
22 |
23 | )
24 | }
25 |
26 | export default MyApp
27 |
--------------------------------------------------------------------------------
/packages/yonode/src/lib/prompt/db.js:
--------------------------------------------------------------------------------
1 | import inquirer from "inquirer";
2 | import { options } from "../../index.js";
3 | import { dbQuestion } from "../questions.js";
4 | import { repoConditions } from "../repoConditions.js";
5 | import { databaseType } from "./dbType.js";
6 |
7 | export const databaseConfirmQuestion = () => {
8 | inquirer
9 | .prompt(dbQuestion)
10 | .then((answer) => {
11 | if (answer.dbQuestion === true) {
12 | databaseType();
13 | } else if(answer.dbQuestion === false) {
14 | options.database = answer.dbQuestion;
15 | repoConditions();
16 | }
17 | })
18 | .catch((error) => {
19 | if (error.isTtyError) {
20 | } else {
21 | }
22 | });
23 | };
24 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-Auth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | import "reflect-metadata";
2 | import { DataSource } from "typeorm";
3 | import { dbName, dbUrl } from "./initialConfig.js";
4 | import chalk from "chalk";
5 | import User from "../entity/User.js";
6 |
7 | const AppDataSource = new DataSource({
8 | type: "mysql",
9 | url: dbUrl,
10 | database: dbName,
11 | entities: [User],
12 | synchronize: true,
13 | });
14 |
15 | AppDataSource.initialize()
16 | .then(async () => {
17 | console.log(`${chalk.green.bold("Connected")} to the database`);
18 | })
19 | .catch((error) =>
20 | console.log(`${chalk.red.bold("Error")} connecting to database`, error)
21 | );
22 |
23 | export default AppDataSource;
24 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-NoAuth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | import "reflect-metadata";
2 | import { DataSource } from "typeorm";
3 | import { dbName, dbUrl } from "./initialConfig.js";
4 | import chalk from "chalk";
5 |
6 | const AppDataSource = new DataSource({
7 | type: "mongodb",
8 | url: dbUrl,
9 | database: dbName,
10 | entities: ["../entity/**/*.js"],
11 | synchronize: true,
12 | authSource: "admin"
13 | });
14 |
15 | AppDataSource.initialize()
16 | .then(async () => {
17 | console.log(`${chalk.green.bold('Connected')} to the database`);
18 | })
19 | .catch((error) =>
20 | console.log(`${chalk.red.bold('Error')} connecting to database`, error)
21 | );
22 |
23 | export default AppDataSource;
24 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | import { Sequelize } from 'sequelize';
2 | import { dbUrl} from './initialConfig.js'
3 | import chalk from 'chalk';
4 |
5 | const sequelize = new Sequelize(dbUrl);
6 | export const connectDB = async () => {
7 | try {
8 | await sequelize.authenticate();
9 | console.log(`${chalk.green.bold('Connected')} to the database`);
10 | await sequelize.sync({ force: true });
11 | console.log(`${chalk.green.bold('Models synced')} successfully`);
12 | } catch (error) {
13 | console.log(`${chalk.red.bold('Error')} connecting to database`, error);
14 | process.exit(1);
15 | }
16 | }
17 |
18 | export default sequelize;
19 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-Auth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | import "reflect-metadata";
2 | import { DataSource } from "typeorm";
3 | import { dbName, dbUrl } from "./initialConfig.js";
4 | import chalk from "chalk";
5 | import User from "../entity/User.js";
6 |
7 | const AppDataSource = new DataSource({
8 | type: "postgres",
9 | url: dbUrl,
10 | database: dbName,
11 | entities: [User],
12 | synchronize: true,
13 | });
14 |
15 | AppDataSource.initialize()
16 | .then(async () => {
17 | console.log(`${chalk.green.bold("Connected")} to the database`);
18 | })
19 | .catch((error) =>
20 | console.log(`${chalk.red.bold("Error")} connecting to database`, error)
21 | );
22 |
23 | export default AppDataSource;
24 |
--------------------------------------------------------------------------------
/yonode.org/components/nav-link/nav-link.tsx:
--------------------------------------------------------------------------------
1 | import { forwardRef } from '@chakra-ui/react'
2 |
3 | import { Button, ButtonProps } from '@saas-ui/react'
4 |
5 | import Link from 'next/link'
6 |
7 | export interface NavLinkProps extends ButtonProps {
8 | isActive?: boolean
9 | href?: string
10 | id?: string
11 | }
12 |
13 | export const NavLink = forwardRef((props, ref) => {
14 | const { href, type, isActive, ...rest } = props
15 |
16 | return (
17 |
27 | )
28 | })
29 |
30 | NavLink.displayName = 'NavLink'
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-Auth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | import "reflect-metadata";
2 | import { DataSource } from "typeorm";
3 | import { dbName, dbUrl } from "./initialConfig.js";
4 | import chalk from "chalk";
5 | import User from "../entity/User.js";
6 |
7 | const AppDataSource = new DataSource({
8 | type: "mongodb",
9 | url: dbUrl,
10 | database: dbName,
11 | entities: [User],
12 | synchronize: true,
13 | authSource: "admin"
14 | });
15 |
16 | AppDataSource.initialize()
17 | .then(async () => {
18 | console.log(`${chalk.green.bold("Connected")} to the database`);
19 | })
20 | .catch((error) =>
21 | console.log(`${chalk.red.bold("Error")} connecting to database`, error)
22 | );
23 |
24 | export default AppDataSource;
25 |
--------------------------------------------------------------------------------
/yonode.org/theme/index.ts:
--------------------------------------------------------------------------------
1 | import { extendTheme } from '@chakra-ui/react'
2 | import { theme } from '@saas-ui/react'
3 |
4 | import components from './components'
5 | import { fontSizes } from './foundations/typography'
6 |
7 | import '@fontsource/inter/variable.css'
8 |
9 | const styles = {
10 | global: (props: any) => ({
11 | body: {
12 | color: 'gray.900',
13 | bg: 'white',
14 | fontSize: 'lg',
15 | _dark: {
16 | color: 'white',
17 | bg: 'gray.900',
18 | },
19 | },
20 | }),
21 | }
22 |
23 | export default extendTheme(
24 | {
25 | config: {
26 | initialColorMode: 'dark',
27 | useSystemColorMode: false,
28 | },
29 | styles,
30 | fontSizes,
31 | components,
32 | },
33 | theme
34 | )
35 |
--------------------------------------------------------------------------------
/yonode.org/contentlayer.config.ts:
--------------------------------------------------------------------------------
1 | import { defineDocumentType, makeSource } from 'contentlayer/source-files'
2 |
3 | export const Post = defineDocumentType(() => ({
4 | name: 'Post',
5 | filePathPattern: `**/*.mdx`,
6 | contentType: 'mdx',
7 | fields: {
8 | title: {
9 | type: 'string',
10 | description: 'The title of the post',
11 | required: true,
12 | },
13 | date: {
14 | type: 'date',
15 | description: 'The date of the post',
16 | required: true,
17 | },
18 | },
19 | computedFields: {
20 | url: {
21 | type: 'string',
22 | resolve: (post) => `/posts/${post._raw.flattenedPath}`,
23 | },
24 | },
25 | }))
26 |
27 | export default makeSource({
28 | contentDirPath: 'posts',
29 | documentTypes: [Post],
30 | })
31 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-Auth-Template/src/routes/authRoutes.js:
--------------------------------------------------------------------------------
1 | // Import required modules and configuration
2 | import express from "express";
3 | import { loginUser, registerUser } from "../controllers/authController.js";
4 | import { validateUserLogin, validateUserRegister } from "../middlewares/validators/authValidator.js";
5 |
6 | // Create a new router instance
7 | const router = express.Router();
8 |
9 | // Register route with input validation followed by the registration controller
10 | router.post("/register", validateUserRegister, registerUser);
11 |
12 | // Login route with input validation followed by the login controller
13 | router.post("/login", validateUserLogin, loginUser);
14 |
15 | // Export the router for use in the main application file
16 | export default router;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-Auth-Template/src/routes/authRoutes.js:
--------------------------------------------------------------------------------
1 | // Import required modules and configuration
2 | import express from "express";
3 | import { loginUser, registerUser } from "../controllers/authController.js";
4 | import { validateUserLogin, validateUserRegister } from "../middlewares/validators/authValidator.js";
5 |
6 | // Create a new router instance
7 | const router = express.Router();
8 |
9 | // Register route with input validation followed by the registration controller
10 | router.post("/register", validateUserRegister, registerUser);
11 |
12 | // Login route with input validation followed by the login controller
13 | router.post("/login", validateUserLogin, loginUser);
14 |
15 | // Export the router for use in the main application file
16 | export default router;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-Auth-Template/src/routes/authRoutes.js:
--------------------------------------------------------------------------------
1 | // Import required modules and configuration
2 | import express from "express";
3 | import { loginUser, registerUser } from "../controllers/authController.js";
4 | import { validateUserLogin, validateUserRegister } from "../middlewares/validators/authValidator.js";
5 |
6 | // Create a new router instance
7 | const router = express.Router();
8 |
9 | // Register route with input validation followed by the registration controller
10 | router.post("/register", validateUserRegister, registerUser);
11 |
12 | // Login route with input validation followed by the login controller
13 | router.post("/login", validateUserLogin, loginUser);
14 |
15 | // Export the router for use in the main application file
16 | export default router;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-Auth-Template/src/routes/authRoutes.js:
--------------------------------------------------------------------------------
1 | // Import required modules and configuration
2 | import express from "express";
3 | import { loginUser, registerUser } from "../controllers/authController.js";
4 | import { validateUserLogin, validateUserRegister } from "../middlewares/validator/authValidator.js";
5 |
6 | // Create a new router instance
7 | const router = express.Router();
8 |
9 | // Register route with input validation followed by the registration controller
10 | router.post("/register", validateUserRegister, registerUser);
11 |
12 | // Login route with input validation followed by the login controller
13 | router.post("/login", validateUserLogin, loginUser);
14 |
15 | // Export the router for use in the main application file
16 | export default router;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-Auth-Template/src/routes/authRoutes.js:
--------------------------------------------------------------------------------
1 | // Import required modules and configuration
2 | import express from "express";
3 | import { loginUser, registerUser } from "../controllers/authController.js";
4 | import { validateUserLogin, validateUserRegister } from "../middlewares/validators/authValidator.js";
5 |
6 | // Create a new router instance
7 | const router = express.Router();
8 |
9 | // Register route with input validation followed by the registration controller
10 | router.post("/register", validateUserRegister, registerUser);
11 |
12 | // Login route with input validation followed by the login controller
13 | router.post("/login", validateUserLogin, loginUser);
14 |
15 | // Export the router for use in the main application file
16 | export default router;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-NoDB-Template/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "no-backend",
3 | "version": "0.0.0",
4 | "private": true,
5 | "main": "./src/app.js",
6 | "type": "module",
7 | "scripts": {
8 | "start": "node ./src/app.js",
9 | "dev": "nodemon ./src/app.js"
10 | },
11 | "dependencies": {
12 | "bcrypt": "^5.1.1",
13 | "chalk": "5.3.0",
14 | "compression": "^1.7.4",
15 | "cookie-parser": "^1.4.6",
16 | "cors": "^2.8.5",
17 | "dotenv": "^16.4.5",
18 | "express": "^4.19.2",
19 | "express-rate-limit": "^7.2.0",
20 | "express-validator": "^7.0.1",
21 | "helmet": "^7.1.0",
22 | "jsonwebtoken": "^9.0.2",
23 | "morgan": "^1.10.0"
24 | },
25 | "devDependencies": {
26 | "yonode": "^1.2.3",
27 | "nodemon": "^3.1.0"
28 | }
29 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-NoAuth-Template/docker-compose.yaml:
--------------------------------------------------------------------------------
1 | version: '3.9'
2 |
3 | services:
4 | db:
5 | image: postgres:latest
6 | container_name: postgres-db
7 | ports:
8 | - '5431:5432'
9 | environment:
10 | POSTGRES_USER: yonode
11 | POSTGRES_PASSWORD: 123321
12 | volumes:
13 | - ./db:/var/lib/postgresql/data
14 | restart: on-failure
15 |
16 | server:
17 | build: .
18 | container_name: yonode-server
19 | restart: on-failure
20 | volumes:
21 | - .:/app
22 | - /app/node_modules
23 | ports:
24 | - '8000:8000'
25 | environment:
26 | DATABASE_URL: ${DATABASE_URL}
27 | SERVER_PORT: ${SERVER_PORT}
28 | NODE_ENVIRONMENT: ${NODE_ENVIRONMENT}
29 | depends_on:
30 | - db
--------------------------------------------------------------------------------
/packages/yonode/src/orm/orm.js:
--------------------------------------------------------------------------------
1 | import inquirer from "inquirer";
2 | import { options } from "../index.js";
3 | import { ormQuestion } from "../lib/questions.js";
4 | import { authType } from "../lib/prompt/auth.js";
5 |
6 | export const ormType = () => {
7 | inquirer
8 | .prompt(ormQuestion)
9 | .then((answer) => {
10 | if (answer.orm_type === "Sequelize") {
11 | options.orm_type = answer.orm_type;
12 | authType()
13 | } else if (answer.orm_type === "Prisma") {
14 | options.orm_type = answer.orm_type;
15 | authType()
16 | } else {
17 | options.orm_type = answer.orm_type;
18 | authType()
19 | }
20 | })
21 | .catch((error) => {
22 | if (error.isTtyError) {
23 | } else {
24 | }
25 | });
26 | };
27 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-Auth-Template/src/routes/authRoutes.js:
--------------------------------------------------------------------------------
1 | // Import required modules and configuration
2 | import express from "express";
3 | import { loginUser, registerUser } from "../controllers/authController.js";
4 | import { validateUserLogin, validateUserRegister } from "../middlewares/validator/authValidator.js";
5 |
6 | // Create a new router instance
7 | const router = express.Router();
8 |
9 | // Register route with input validation followed by the registration controller
10 | router.post("/register", validateUserRegister, registerUser);
11 |
12 | // Login route with input validation followed by the login controller
13 | router.post("/login", validateUserLogin, loginUser);
14 |
15 | // Export the router for use in the main application file
16 | export default router;
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-Auth-Template/src/routes/authRoutes.js:
--------------------------------------------------------------------------------
1 | // Import required modules and configuration
2 | import express from "express";
3 | import { loginUser, registerUser } from "../controllers/authController.js";
4 | import { validateUserLogin, validateUserRegister } from "../middlewares/validators/authValidator.js";
5 |
6 | // Create a new router instance
7 | const router = express.Router();
8 |
9 | // Register route with input validation followed by the registration controller
10 | router.post("/register", validateUserRegister, registerUser);
11 |
12 | // Login route with input validation followed by the login controller
13 | router.post("/login", validateUserLogin, loginUser);
14 |
15 | // Export the router for use in the main application file
16 | export default router;
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "author": "Mr Sharafdin",
4 | "license": "MIT",
5 | "homepage": "https://yonode.org/",
6 | "engines": {
7 | "node": "^18.0.0 || >=20.0.0"
8 | },
9 | "repository": "git+https://github.com/sharafdin/yonode.git",
10 | "keywords": [
11 | "yonode",
12 | "api",
13 | "server",
14 | "backend"
15 | ],
16 | "scripts": {
17 | "lint": "eslint . --fix",
18 | "prettier-check": "prettier --check .",
19 | "format": "prettier --write ."
20 | },
21 | "devDependencies": {
22 | "eslint": "8.57.0",
23 | "eslint-config-prettier": "^9.1.0",
24 | "eslint-plugin-prettier": "^5.1.3",
25 | "prettier": "^3.2.5",
26 | "@eslint/js": "^9.2.0",
27 | "globals": "^15.2.0",
28 | "typescript-eslint": "^7.8.0"
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-Auth-Template/src/utils/passwordUtils.js:
--------------------------------------------------------------------------------
1 | import bcrypt from "bcrypt";
2 |
3 | // Function to generate a hashed password asynchronously
4 | export const hashPassword = async (password) => {
5 | // Generate a salt with a cost factor of 12
6 | const salt = await bcrypt.genSalt(12);
7 | // Hash the provided password using the generated salt
8 | const hashedPassword = await bcrypt.hash(password, salt);
9 | // Return the hashed password
10 | return hashedPassword;
11 | };
12 |
13 | // Function to compare a plain password with a hashed password asynchronously
14 | export const comparePassword = async (password, hashedPassword) => {
15 | // Compare the provided password with the hashed password securely
16 | return await bcrypt.compare(password, hashedPassword);
17 | };
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-Auth-Template/src/utils/passwordUtils.js:
--------------------------------------------------------------------------------
1 | import bcrypt from "bcrypt";
2 |
3 | // Function to generate a hashed password asynchronously
4 | export const hashPassword = async (password) => {
5 | // Generate a salt with a cost factor of 12
6 | const salt = await bcrypt.genSalt(12);
7 | // Hash the provided password using the generated salt
8 | const hashedPassword = await bcrypt.hash(password, salt);
9 | // Return the hashed password
10 | return hashedPassword;
11 | };
12 |
13 | // Function to compare a plain password with a hashed password asynchronously
14 | export const comparePassword = async (password, hashedPassword) => {
15 | // Compare the provided password with the hashed password securely
16 | return await bcrypt.compare(password, hashedPassword);
17 | };
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-Auth-Template/src/utils/passwordUtils.js:
--------------------------------------------------------------------------------
1 | import bcrypt from "bcrypt";
2 |
3 | // Function to generate a hashed password asynchronously
4 | export const hashPassword = async (password) => {
5 | // Generate a salt with a cost factor of 12
6 | const salt = await bcrypt.genSalt(12);
7 | // Hash the provided password using the generated salt
8 | const hashedPassword = await bcrypt.hash(password, salt);
9 | // Return the hashed password
10 | return hashedPassword;
11 | };
12 |
13 | // Function to compare a plain password with a hashed password asynchronously
14 | export const comparePassword = async (password, hashedPassword) => {
15 | // Compare the provided password with the hashed password securely
16 | return await bcrypt.compare(password, hashedPassword);
17 | };
18 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-Auth-Template/src/utils/passwordUtils.js:
--------------------------------------------------------------------------------
1 | import bcrypt from "bcrypt";
2 |
3 | // Function to generate a hashed password asynchronously
4 | export const hashPassword = async (password) => {
5 | // Generate a salt with a cost factor of 12
6 | const salt = await bcrypt.genSalt(12);
7 | // Hash the provided password using the generated salt
8 | const hashedPassword = await bcrypt.hash(password, salt);
9 | // Return the hashed password
10 | return hashedPassword;
11 | };
12 |
13 | // Function to compare a plain password with a hashed password asynchronously
14 | export const comparePassword = async (password, hashedPassword) => {
15 | // Compare the provided password with the hashed password securely
16 | return await bcrypt.compare(password, hashedPassword);
17 | };
18 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-Auth-Template/src/utils/passwordUtils.js:
--------------------------------------------------------------------------------
1 | import bcrypt from "bcrypt";
2 |
3 | // Function to generate a hashed password asynchronously
4 | export const hashPassword = async (password) => {
5 | // Generate a salt with a cost factor of 12
6 | const salt = await bcrypt.genSalt(12);
7 | // Hash the provided password using the generated salt
8 | const hashedPassword = await bcrypt.hash(password, salt);
9 | // Return the hashed password
10 | return hashedPassword;
11 | };
12 |
13 | // Function to compare a plain password with a hashed password asynchronously
14 | export const comparePassword = async (password, hashedPassword) => {
15 | // Compare the provided password with the hashed password securely
16 | return await bcrypt.compare(password, hashedPassword);
17 | };
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-Auth-Template/src/utils/passwordUtils.js:
--------------------------------------------------------------------------------
1 | import bcrypt from "bcrypt";
2 |
3 | // Function to generate a hashed password asynchronously
4 | export const hashPassword = async (password) => {
5 | // Generate a salt with a cost factor of 12
6 | const salt = await bcrypt.genSalt(12);
7 | // Hash the provided password using the generated salt
8 | const hashedPassword = await bcrypt.hash(password, salt);
9 | // Return the hashed password
10 | return hashedPassword;
11 | };
12 |
13 | // Function to compare a plain password with a hashed password asynchronously
14 | export const comparePassword = async (password, hashedPassword) => {
15 | // Compare the provided password with the hashed password securely
16 | return await bcrypt.compare(password, hashedPassword);
17 | };
--------------------------------------------------------------------------------
/.github/workflows/publish.yaml:
--------------------------------------------------------------------------------
1 | name: Publish Yonode Package
2 |
3 | on:
4 | push:
5 | tags:
6 | - "v*" # Push events to matching v*, i.e. v1.0, v20.15.10
7 |
8 | jobs:
9 | publish:
10 | # prevents this action from running on forks
11 | if: github.repository == 'sharafdin/yonode'
12 | name: Publish Yonode Package
13 | runs-on: ubuntu-latest
14 |
15 | steps:
16 | - uses: actions/checkout@v2
17 |
18 | - name: Setup Node.js
19 | uses: actions/setup-node@v2
20 | with:
21 | node-version: '16'
22 | registry-url: 'https://registry.npmjs.org/'
23 | - name: Publish to npm
24 | run: npm publish --access public
25 | working-directory: packages/yonode
26 | env:
27 | NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
28 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-Auth-Template/src/utils/passwordUtils.js:
--------------------------------------------------------------------------------
1 | import bcrypt from "bcrypt";
2 |
3 | // Function to generate a hashed password asynchronously
4 | export const hashPassword = async (password) => {
5 | // Generate a salt with a cost factor of 12
6 | const salt = await bcrypt.genSalt(12);
7 | // Hash the provided password using the generated salt
8 | const hashedPassword = await bcrypt.hash(password, salt);
9 | // Return the hashed password
10 | return hashedPassword;
11 | };
12 |
13 | // Function to compare a plain password with a hashed password asynchronously
14 | export const comparePassword = async (password, hashedPassword) => {
15 | // Compare the provided password with the hashed password securely
16 | return await bcrypt.compare(password, hashedPassword);
17 | };
18 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-Auth-Template/src/utils/passwordUtils.js:
--------------------------------------------------------------------------------
1 | import bcrypt from "bcrypt";
2 |
3 | // Function to generate a hashed password asynchronously
4 | export const hashPassword = async (password) => {
5 | // Generate a salt with a cost factor of 12
6 | const salt = await bcrypt.genSalt(12);
7 | // Hash the provided password using the generated salt
8 | const hashedPassword = await bcrypt.hash(password, salt);
9 | // Return the hashed password
10 | return hashedPassword;
11 | };
12 |
13 | // Function to compare a plain password with a hashed password asynchronously
14 | export const comparePassword = async (password, hashedPassword) => {
15 | // Compare the provided password with the hashed password securely
16 | return await bcrypt.compare(password, hashedPassword);
17 | };
18 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-Auth-Template/src/utils/passwordUtils.js:
--------------------------------------------------------------------------------
1 | import bcrypt from "bcrypt";
2 |
3 | // Function to generate a hashed password asynchronously
4 | export const hashPassword = async (password) => {
5 | // Generate a salt with a cost factor of 12
6 | const salt = await bcrypt.genSalt(12);
7 | // Hash the provided password using the generated salt
8 | const hashedPassword = await bcrypt.hash(password, salt);
9 | // Return the hashed password
10 | return hashedPassword;
11 | };
12 |
13 | // Function to compare a plain password with a hashed password asynchronously
14 | export const comparePassword = async (password, hashedPassword) => {
15 | // Compare the provided password with the hashed password securely
16 | return await bcrypt.compare(password, hashedPassword);
17 | };
18 |
--------------------------------------------------------------------------------
/packages/yonode/src/orm/mongoDB.js:
--------------------------------------------------------------------------------
1 | import inquirer from "inquirer";
2 | import { options } from "../index.js";
3 | import { mongodbOrmQuestion } from "../lib/questions.js";
4 | import { authType } from "../lib/prompt/auth.js";
5 |
6 | export const mongodbOrm = () => {
7 | inquirer
8 | .prompt(mongodbOrmQuestion)
9 | .then((answer) => {
10 | if (answer.mongodb_orm === "Mongoose") {
11 | options.orm_type = answer.mongodb_orm;
12 | authType();
13 | } else if (answer.mongodb_orm === "Prisma") {
14 | options.orm_type = answer.mongodb_orm;
15 | authType();
16 | } else {
17 | options.orm_type = answer.mongodb_orm;
18 | authType();
19 | }
20 | })
21 | .catch((error) => {
22 | if (error.isTtyError) {
23 | } else {
24 | }
25 | });
26 | };
27 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-Auth-Template/docker-compose.yaml:
--------------------------------------------------------------------------------
1 | version: '3.9'
2 |
3 | services:
4 | db:
5 | image: postgres:latest
6 | container_name: postgres-db
7 | ports:
8 | - '5431:5432'
9 | environment:
10 | POSTGRES_USER: yonode
11 | POSTGRES_PASSWORD: 123321
12 | volumes:
13 | - ./db:/var/lib/postgresql/data
14 | restart: on-failure
15 |
16 | server:
17 | build: .
18 | container_name: yonode-server
19 | restart: on-failure
20 | volumes:
21 | - .:/app
22 | - /app/node_modules
23 | ports:
24 | - '8000:8000'
25 | environment:
26 | DATABASE_URL: ${DATABASE_URL}
27 | SERVER_PORT: ${SERVER_PORT}
28 | JWT_SECRET_KEY: ${JWT_SECRET_KEY}
29 | NODE_ENVIRONMENT: ${NODE_ENVIRONMENT}
30 | depends_on:
31 | - db
--------------------------------------------------------------------------------
/yonode.org/theme/components/cta.ts:
--------------------------------------------------------------------------------
1 | const CTA = {
2 | parts: ['wrapper', 'title', 'action', 'secondaryAction'],
3 | baseStyle: {
4 | wrapper: {
5 | pt: 28,
6 | pb: 28,
7 | },
8 | action: {
9 | colorScheme: 'primary',
10 | },
11 | secondaryAction: {
12 | colorScheme: 'primary',
13 | variant: 'ghost',
14 | },
15 | },
16 | variants: {
17 | subtle: {},
18 | solid: {
19 | wrapper: {
20 | bg: 'primary.400',
21 | },
22 | secondaryAction: {
23 | colorScheme: 'white',
24 | },
25 | },
26 | light: ({ colorMode }: any) => ({
27 | wrapper: {
28 | bg: colorMode === 'dark' ? 'gray.700' : 'gray.100',
29 | },
30 | }),
31 | },
32 | defaultProps: {
33 | variant: 'subtle',
34 | },
35 | }
36 |
37 | export default CTA
38 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "yonode-api",
3 | "version": "0.0.0",
4 | "private": true,
5 | "main": "./src/app.js",
6 | "type": "module",
7 | "scripts": {
8 | "start": "node ./src/app.js",
9 | "dev": "nodemon ./src/app.js"
10 | },
11 | "dependencies": {
12 | "bcrypt": "^5.1.1",
13 | "chalk": "5.3.0",
14 | "compression": "^1.7.4",
15 | "cookie-parser": "^1.4.6",
16 | "cors": "^2.8.5",
17 | "dotenv": "^16.4.5",
18 | "express": "^4.19.2",
19 | "express-rate-limit": "^7.2.0",
20 | "express-validator": "^7.0.1",
21 | "helmet": "^7.1.0",
22 | "jsonwebtoken": "^9.0.2",
23 | "mongoose": "^8.3.4",
24 | "morgan": "^1.10.0"
25 | },
26 | "devDependencies": {
27 | "yonode": "^1.2.3",
28 | "nodemon": "^3.1.0"
29 | }
30 | }
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/docker-compose.yaml:
--------------------------------------------------------------------------------
1 | version: '3.9'
2 |
3 | services:
4 | db:
5 | image: postgres:latest
6 | container_name: postgres-db
7 | ports:
8 | - '5431:5432'
9 | environment:
10 | POSTGRES_USER: yonode
11 | POSTGRES_PASSWORD: 123321
12 | volumes:
13 | - ./db:/var/lib/postgresql/data
14 | restart: on-failure:5
15 |
16 | server:
17 | build: .
18 | container_name: yonode-server
19 | restart: on-failure:5
20 | volumes:
21 | - .:/app
22 | - /app/node_modules
23 | ports:
24 | - '8000:8000'
25 | environment:
26 | SERVER_PORT: ${SERVER_PORT}
27 | DATABASE_URL: ${DATABASE_URL}
28 | DATABASE_NAME: ${DATABASE_NAME}
29 | NODE_ENVIRONMENT: ${NODE_ENVIRONMENT}
30 | depends_on:
31 | - db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/docker-compose.yaml:
--------------------------------------------------------------------------------
1 | version: '3.9'
2 |
3 | services:
4 | db:
5 | image: postgres:latest
6 | container_name: postgres-db
7 | ports:
8 | - '5431:5432'
9 | environment:
10 | POSTGRES_USER: yonode
11 | POSTGRES_PASSWORD: 123321
12 | volumes:
13 | - ./db:/var/lib/postgresql/data
14 | restart: on-failure:5
15 |
16 | server:
17 | build: .
18 | container_name: yonode-server
19 | restart: on-failure:5
20 | volumes:
21 | - .:/app
22 | - /app/node_modules
23 | ports:
24 | - '8000:8000'
25 | environment:
26 | SERVER_PORT: ${SERVER_PORT}
27 | DATABASE_URL: ${DATABASE_URL}
28 | DATABASE_NAME: ${DATABASE_NAME}
29 | NODE_ENVIRONMENT: ${NODE_ENVIRONMENT}
30 | depends_on:
31 | - db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-Auth-Template/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "yonode-api",
3 | "version": "0.0.0",
4 | "private": true,
5 | "main": "./src/app.js",
6 | "type": "module",
7 | "scripts": {
8 | "start": "node ./src/app.js",
9 | "dev": "nodemon ./src/app.js"
10 | },
11 | "dependencies": {
12 | "bcrypt": "^5.1.1",
13 | "chalk": "5.3.0",
14 | "compression": "^1.7.4",
15 | "cookie-parser": "^1.4.6",
16 | "cors": "^2.8.5",
17 | "dotenv": "^16.4.5",
18 | "express": "^4.19.2",
19 | "express-rate-limit": "^7.2.0",
20 | "express-validator": "^7.0.1",
21 | "helmet": "^7.1.0",
22 | "jsonwebtoken": "^9.0.2",
23 | "mongoose": "^8.3.4",
24 | "morgan": "^1.10.0"
25 | },
26 | "devDependencies": {
27 | "nodemon": "^3.1.0",
28 | "yonode": "^1.2.3"
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-Auth-Template/docker-compose.yaml:
--------------------------------------------------------------------------------
1 | version: '3.9'
2 |
3 | services:
4 | db:
5 | image: mysql:latest
6 | container_name: mysql-db
7 | ports:
8 | - '5431:5432'
9 | environment:
10 | MYSQL_USER: yonode
11 | MYSQL_PASSWORD: 123321
12 | MYSQL_ROOT_PASSWORD: root
13 | volumes:
14 | - ./db:/var/lib/mysql
15 | restart: on-failure
16 |
17 | server:
18 | build: .
19 | container_name: yonode-server
20 | restart: on-failure
21 | volumes:
22 | - .:/app
23 | - /app/node_modules
24 | ports:
25 | - '8000:8000'
26 | environment:
27 | DATABASE_URL: ${DATABASE_URL}
28 | SERVER_PORT: ${SERVER_PORT}
29 | JWT_SECRET_KEY: ${JWT_SECRET_KEY}
30 | NODE_ENVIRONMENT: ${NODE_ENVIRONMENT}
31 | depends_on:
32 | - db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-NoAuth-Template/docker-compose.yaml:
--------------------------------------------------------------------------------
1 | version: '3.9'
2 |
3 | services:
4 | db:
5 | image: mysql:latest
6 | container_name: mysql-db
7 | ports:
8 | - '5431:5432'
9 | environment:
10 | MYSQL_USER: yonode
11 | MYSQL_PASSWORD: 123321
12 | MYSQL_ROOT_PASSWORD: root
13 | volumes:
14 | - ./db:/var/lib/mysql
15 | restart: on-failure
16 |
17 | server:
18 | build: .
19 | container_name: yonode-server
20 | restart: on-failure
21 | volumes:
22 | - .:/app
23 | - /app/node_modules
24 | ports:
25 | - '8000:8000'
26 | environment:
27 | DATABASE_URL: ${DATABASE_URL}
28 | SERVER_PORT: ${SERVER_PORT}
29 | JWT_SECRET_KEY: ${JWT_SECRET_KEY}
30 | NODE_ENVIRONMENT: ${NODE_ENVIRONMENT}
31 | depends_on:
32 | - db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | // Import required modules and configuration
2 | import mongoose from 'mongoose'
3 | import { dbName, dbUrl } from './initialConfig.js'
4 | import chalk from 'chalk'
5 |
6 | // Async function to connect to the MongoDB database
7 | const connectDB = async () => {
8 | try {
9 | // Connect to the database with the provided URL and name
10 | await mongoose.connect(dbUrl, { dbName })
11 | // Log success message in green
12 | console.log(`${chalk.green.bold('Connected')} to the database`)
13 | } catch (error) {
14 | // Log error message in red and exit the application
15 | console.log(`${chalk.red.bold('Error')} connecting to database`, error)
16 | process.exit(1)
17 | }
18 | }
19 |
20 | // Export the connectDB function
21 | export default connectDB
22 |
--------------------------------------------------------------------------------
/yonode.org/components/testimonials/testimonials.tsx:
--------------------------------------------------------------------------------
1 | import { ResponsiveValue, SimpleGrid, Stack } from '@chakra-ui/react'
2 | import {
3 | Section,
4 | SectionProps,
5 | SectionTitle,
6 | SectionTitleProps,
7 | } from 'components/section'
8 | import { Testimonial } from './testimonial'
9 |
10 | export interface TestimonialsProps
11 | extends Omit,
12 | Pick {
13 | columns?: ResponsiveValue
14 | }
15 |
16 | export const Testimonials: React.FC = (props) => {
17 | const { children, title, columns = [1, null, 2], ...rest } = props
18 | return (
19 |
20 |
21 |
22 | {children}
23 |
24 |
25 | )
26 | }
27 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-Auth-Template/src/config/dbConfig.js:
--------------------------------------------------------------------------------
1 | // Import required modules and configuration
2 | import mongoose from "mongoose";
3 | import { dbName, dbUrl } from "./initialConfig.js";
4 | import chalk from "chalk";
5 |
6 | // Async function to connect to the MongoDB database
7 | const connectDB = async () => {
8 | try {
9 | // Connect to the database with the provided URL and name
10 | await mongoose.connect(dbUrl, { dbName });
11 | // Log success message in green
12 | console.log(`${chalk.green.bold("Connected")} to the database`);
13 | } catch (error) {
14 | // Log error message in red and exit the application
15 | console.log(`${chalk.red.bold("Error")} connecting to database`, error);
16 | process.exit(1);
17 | }
18 | };
19 |
20 | // Export the connectDB function
21 | export default connectDB;
22 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-NoDB-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
27 |
28 | ## NOTES
29 |
30 | ### Using Docker
31 |
32 | To use Docker, you do not need to install `node_modules` locally. Simply run the following command:
33 |
34 | ```bash
35 | docker-compose up
36 | ```
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-Auth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-Auth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-NoAuth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-Auth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-Auth-Template/.gitIgnore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-Auth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
--------------------------------------------------------------------------------
/yonode.org/components/section/section.tsx:
--------------------------------------------------------------------------------
1 | import {
2 | chakra,
3 | useStyleConfig,
4 | omitThemingProps,
5 | Container,
6 | ThemingProps,
7 | StyleProps,
8 | HTMLChakraProps,
9 | } from '@chakra-ui/react'
10 |
11 | export interface SectionProps
12 | extends HTMLChakraProps<'div'>,
13 | ThemingProps<'Section'> {
14 | children: React.ReactNode
15 | innerWidth?: StyleProps['width']
16 | }
17 |
18 | export const Section: React.FC = (props) => {
19 | const { children, innerWidth = 'container.lg', className, ...rest } = props
20 | const styles = useStyleConfig('Section', rest)
21 |
22 | const ownProps = omitThemingProps(rest)
23 |
24 | return (
25 |
26 |
27 | {children}
28 |
29 |
30 | )
31 | }
32 |
--------------------------------------------------------------------------------
/docs.yonode.org/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "yonode-docs",
3 | "version": "0.0.1",
4 | "description": "Nextra docs template",
5 | "scripts": {
6 | "dev": "next dev",
7 | "build": "next build",
8 | "start": "next start"
9 | },
10 | "repository": {
11 | "type": "git",
12 | "url": "git+https://github.com/sharafdin/yonode-docs.git"
13 | },
14 | "license": "MIT",
15 | "bugs": {
16 | "url": "https://github.com/sharafdin/yonode-docs/issues"
17 | },
18 | "homepage": "https://github.com/sharafdin/yonode-docs#readme",
19 | "dependencies": {
20 | "next": "^13.5.1",
21 | "nextra": "latest",
22 | "nextra-theme-docs": "latest",
23 | "react": "^18.3.1",
24 | "react-dom": "^18.3.1",
25 | "yonode": "^1.2.3"
26 | },
27 | "devDependencies": {
28 | "@types/node": "20.12.10",
29 | "typescript": "^5.4.5"
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-Auth-Template/docker-compose.yaml:
--------------------------------------------------------------------------------
1 | version: '3.9'
2 |
3 | services:
4 | db:
5 | image: mongo:latest
6 | container_name: mongo-db
7 | ports:
8 | - '27017:27017'
9 | restart: on-failure
10 | # healthcheck:
11 | # test: echo 'db.stats().ok' | mongo localhost:27017/test --quiet
12 | # interval: 10s
13 | # timeout: 5s
14 | # retries: 5
15 |
16 |
17 | server:
18 | build: .
19 | container_name: yonode-server
20 | restart: on-failure
21 | volumes:
22 | - .:/app
23 | - /app/node_modules
24 | ports:
25 | - '8000:8000'
26 | environment:
27 | DATABASE_URL: ${DATABASE_URL}
28 | SERVER_PORT: ${SERVER_PORT}
29 | JWT_SECRET_KEY: ${JWT_SECRET_KEY}
30 | NODE_ENVIRONMENT: ${NODE_ENVIRONMENT}
31 | depends_on:
32 | - db
33 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Mongoose-NoAuth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-NoAuth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-Auth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
51 | db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-Auth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
51 | db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-NoAuth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
51 | db
52 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-NoAuth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 | package-lock
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-Auth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
51 |
52 | db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-Auth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
51 | db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-NoAuth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
51 | db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-Auth-Template/docker-compose.yaml:
--------------------------------------------------------------------------------
1 | version: '3.9'
2 |
3 | services:
4 | db:
5 | image: postgres:latest
6 | container_name: postgres-db
7 | ports:
8 | - '5431:5432'
9 | environment:
10 | POSTGRES_USER: yonode
11 | POSTGRES_PASSWORD: 123321
12 | volumes:
13 | - ./db:/var/lib/postgresql/data
14 | restart: on-failure:5
15 |
16 | server:
17 | build: .
18 | container_name: yonode-server
19 | restart: on-failure:5
20 | volumes:
21 | - .:/app
22 | - /app/node_modules
23 | ports:
24 | - '8000:8000'
25 | environment:
26 | SERVER_PORT: ${SERVER_PORT}
27 | DATABASE_URL: ${DATABASE_URL}
28 | DATABASE_NAME: ${DATABASE_NAME}
29 | JWT_SECRET_KEY: ${JWT_SECRET_KEY}
30 | NODE_ENVIRONMENT: ${NODE_ENVIRONMENT}
31 | depends_on:
32 | - db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-NoAuth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 |
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 | .env
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
51 | db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-NoAuth-Template/src/controllers/helloWorldController.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Hello World controller
3 | *
4 | * This is a simple controller that returns a "Hello World" message
5 | * in the response body. It is a good example of how to create a basic
6 | * controller in Yonode.
7 | *
8 | * @param {Object} res The Express.js response object
9 | * @param {Object} req The Express.js request object
10 | */
11 | export const helloWorld = async (req, res) => {
12 | try {
13 |
14 | // Send a "Hello World" message in the response body
15 | res.send("Hello World");
16 |
17 | } catch (err) {
18 | // If there is an error, send a 500 Internal Server Error
19 | // with a message in the response body
20 | res.status(500).json({
21 | message: "Internal Server Error"
22 | });
23 | }
24 | }
25 |
26 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Sequelize-NoAuth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 | package-lock
8 |
9 | # Yarn and npm cache directories
10 | .yarn/cache/
11 | .npm/
12 |
13 | # TypeScript cache
14 | *.tsbuildinfo
15 |
16 | # Optional cache directories
17 | .eslintcache
18 | .stylelintcache
19 |
20 | # Environment variables
21 | .env
22 | .env.development.local
23 | .env.test.local
24 | .env.production.local
25 | .env.local
26 |
27 | # Build output
28 | dist/
29 | build/
30 | out/
31 |
32 | # Coverage directory used by tools like istanbul
33 | coverage/
34 |
35 | # Editor-specific files
36 | .vscode/
37 | .idea/
38 | *.swp
39 |
40 | # Temporary files
41 | *.tmp
42 | *.temp
43 |
44 | # OS-specific files
45 | .DS_Store
46 | Thumbs.db
47 |
48 | # Miscellaneous
49 | .node_repl_history
50 | .vscode-test
51 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Sequelize-Auth-Template/docker-compose.yaml:
--------------------------------------------------------------------------------
1 | version: '3.9'
2 |
3 | services:
4 | db:
5 | image: postgres:latest
6 | container_name: postgres-db
7 | ports:
8 | - '5431:5432'
9 | environment:
10 | POSTGRES_USER: yonode
11 | POSTGRES_PASSWORD: 123321
12 | volumes:
13 | - ./db:/var/lib/postgresql/data
14 | restart: on-failure:5
15 |
16 | server:
17 | build: .
18 | container_name: yonode-server
19 | restart: on-failure:5
20 | volumes:
21 | - .:/app
22 | - /app/node_modules
23 | ports:
24 | - '8000:8000'
25 | environment:
26 | SERVER_PORT: ${SERVER_PORT}
27 | DATABASE_URL: ${DATABASE_URL}
28 | DATABASE_NAME: ${DATABASE_NAME}
29 | JWT_SECRET_KEY: ${JWT_SECRET_KEY}
30 | NODE_ENVIRONMENT: ${NODE_ENVIRONMENT}
31 | depends_on:
32 | - db
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-NoAuth-Template/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs and Runtime data
2 | logs/
3 | *.log
4 |
5 | # Dependency directories
6 | node_modules/
7 | package-lock.json
8 | # Yarn and npm cache directories
9 | .yarn/cache/
10 | .npm/
11 |
12 | # TypeScript cache
13 | *.tsbuildinfo
14 |
15 | # Optional cache directories
16 | .eslintcache
17 | .stylelintcache
18 |
19 | # Environment variables
20 |
21 | .env.development.local
22 | .env.test.local
23 | .env.production.local
24 | .env.local
25 |
26 | # Build output
27 | dist/
28 | build/
29 | out/
30 |
31 | # Coverage directory used by tools like istanbul
32 | coverage/
33 |
34 | # Editor-specific files
35 | .vscode/
36 | .idea/
37 | *.swp
38 |
39 | # Temporary files
40 | *.tmp
41 | *.temp
42 |
43 | # OS-specific files
44 | .DS_Store
45 | Thumbs.db
46 |
47 | # Miscellaneous
48 | .node_repl_history
49 | .vscode-test
50 |
51 | db
52 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-Prisma-Auth-Template/README.md:
--------------------------------------------------------------------------------
1 | # Yonode + PostgreSQL with Prisma
2 |
3 | This template simplifies setting up a server in [Yonode](https://yonode.org) with Node.js and Express, offering a quick start for server-side development.
4 |
5 | ## Getting Started
6 |
7 | Initially, navigate to the .env file to set up the required environment variables.
8 |
9 | Next, launch the development server:
10 |
11 | ```bash
12 | npm start
13 | # or
14 | yarn start
15 | # or
16 | pnpm start
17 | # or
18 | bun start
19 | ```
20 |
21 | The server is running and ready to serve requests.
22 |
23 | Now, Go to the Src directory and start building the server.
24 |
25 | Happy coding!
26 |
27 |
28 | ## NOTES
29 |
30 | ### Using Docker
31 |
32 | To use Docker, you do not need to install `node_modules` locally. Simply run the following command:
33 |
34 | ```bash
35 | docker-compose up
36 | ```
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-Prisma-Auth-Template/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "yonode-api",
3 | "version": "0.0.0",
4 | "private": true,
5 | "main": "./src/app.js",
6 | "type": "module",
7 | "scripts": {
8 | "start": "node ./src/app.js",
9 | "dev": "nodemon ./src/app.js"
10 | },
11 | "dependencies": {
12 | "@prisma/client": "^5.13.0",
13 | "bcrypt": "^5.1.1",
14 | "chalk": "5.3.0",
15 | "compression": "^1.7.4",
16 | "cookie-parser": "^1.4.6",
17 | "cors": "^2.8.5",
18 | "dotenv": "^16.4.5",
19 | "express": "^4.19.2",
20 | "express-rate-limit": "^7.2.0",
21 | "express-validator": "^7.0.1",
22 | "helmet": "^7.1.0",
23 | "jsonwebtoken": "^9.0.2",
24 | "mongoose": "^8.3.4",
25 | "morgan": "^1.10.0",
26 | "prisma": "^5.13.0"
27 | },
28 | "devDependencies": {
29 | "nodemon": "^3.1.0",
30 | "yonode": "^1.2.3"
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MongoDB-TypeORM-Auth-Template/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "yonode-api",
3 | "version": "0.0.0",
4 | "private": true,
5 | "main": "./src/app.js",
6 | "type": "module",
7 | "scripts": {
8 | "start": "node ./src/app.js",
9 | "dev": "nodemon ./src/app.js"
10 | },
11 | "dependencies": {
12 | "bcrypt": "^5.1.1",
13 | "chalk": "5.3.0",
14 | "compression": "^1.7.4",
15 | "cookie-parser": "^1.4.6",
16 | "cors": "^2.8.5",
17 | "dotenv": "^16.4.5",
18 | "express": "^4.19.2",
19 | "express-rate-limit": "^7.2.0",
20 | "express-validator": "^7.0.1",
21 | "helmet": "^7.1.0",
22 | "jsonwebtoken": "^9.0.2",
23 | "mongodb": "^6.6.1",
24 | "morgan": "^1.10.0",
25 | "reflect-metadata": "^0.2.2",
26 | "typeorm": "0.3.20"
27 | },
28 | "devDependencies": {
29 | "nodemon": "^3.1.0",
30 | "yonode": "^1.2.3"
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-Prisma-Auth-Template/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "yonode-api",
3 | "version": "0.0.0",
4 | "private": true,
5 | "main": "./src/app.js",
6 | "type": "module",
7 | "scripts": {
8 | "start": "node ./src/app.js",
9 | "dev": "nodemon ./src/app.js"
10 | },
11 | "dependencies": {
12 | "@prisma/client": "^5.13.0",
13 | "bcrypt": "^5.1.1",
14 | "chalk": "5.3.0",
15 | "compression": "^1.7.4",
16 | "cookie-parser": "^1.4.6",
17 | "cors": "^2.8.5",
18 | "dotenv": "^16.4.5",
19 | "express": "^4.19.2",
20 | "express-rate-limit": "^7.2.0",
21 | "express-validator": "^7.0.1",
22 | "helmet": "^7.1.0",
23 | "jsonwebtoken": "^9.0.2",
24 | "mongoose": "^8.3.4",
25 | "morgan": "^1.10.0",
26 | "prisma": "^5.13.0"
27 | },
28 | "devDependencies": {
29 | "nodemon": "^3.1.0",
30 | "yonode": "^1.2.3"
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-MySQL-TypeORM-Auth-Template/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "yonode-api",
3 | "version": "0.0.0",
4 | "private": true,
5 | "main": "./src/app.js",
6 | "type": "module",
7 | "scripts": {
8 | "start": "node ./src/app.js",
9 | "dev": "nodemon ./src/app.js"
10 | },
11 | "dependencies": {
12 | "bcrypt": "^5.1.1",
13 | "chalk": "5.3.0",
14 | "compression": "^1.7.4",
15 | "cookie-parser": "^1.4.6",
16 | "cors": "^2.8.5",
17 | "dotenv": "^16.4.5",
18 | "express": "^4.19.2",
19 | "express-rate-limit": "^7.2.0",
20 | "express-validator": "^7.0.1",
21 | "helmet": "^7.1.0",
22 | "jsonwebtoken": "^9.0.2",
23 | "mysql2": "^3.9.7",
24 | "morgan": "^1.10.0",
25 | "reflect-metadata": "^0.2.2",
26 | "typeorm": "0.3.20"
27 | },
28 | "devDependencies": {
29 | "nodemon": "^3.1.0",
30 | "yonode": "^1.2.3"
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/packages/yonode-templates/JS-PostgreSQL-TypeORM-Auth-Template/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "yonode-api",
3 | "version": "0.0.0",
4 | "private": true,
5 | "main": "./src/app.js",
6 | "type": "module",
7 | "scripts": {
8 | "start": "node ./src/app.js",
9 | "dev": "nodemon ./src/app.js"
10 | },
11 | "dependencies": {
12 | "bcrypt": "^5.1.1",
13 | "chalk": "5.3.0",
14 | "compression": "^1.7.4",
15 | "cookie-parser": "^1.4.6",
16 | "cors": "^2.8.5",
17 | "dotenv": "^16.4.5",
18 | "express": "^4.19.2",
19 | "express-rate-limit": "^7.2.0",
20 | "express-validator": "^7.0.1",
21 | "helmet": "^7.1.0",
22 | "jsonwebtoken": "^9.0.2",
23 | "morgan": "^1.10.0",
24 | "pg": "^8.11.5",
25 | "reflect-metadata": "^0.2.2",
26 | "typeorm": "0.3.20"
27 | },
28 | "devDependencies": {
29 | "nodemon": "^3.1.0",
30 | "yonode": "^1.2.3"
31 | }
32 | }
33 |
--------------------------------------------------------------------------------