Skip to content

Commit

Permalink
Merge branch 'main' into dependabot/npm_and_yarn/typescript-5.2.2
Browse files Browse the repository at this point in the history
  • Loading branch information
vygandas committed Oct 29, 2023
2 parents 67d7b03 + c64220e commit d96f88e
Show file tree
Hide file tree
Showing 13 changed files with 12,961 additions and 30,218 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
Expand Down
11 changes: 8 additions & 3 deletions .github/workflows/pr_affected_code.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,23 @@ jobs:
matrix:
node-version: [18.x, 20.x]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}

- run: git fetch origin main

- run: yarn install
- uses: pnpm/action-setup@v2
with:
version: 8
run_install: false

- run: pnpm install --no-prefer-frozen-lockfile

- name: Run Affected Tests
shell: bash
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,5 @@ Thumbs.db
.next

documentation

.pnpm-store
22 changes: 19 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
#!/usr/bin/make

# --- Load in .env ---

ifneq ("$(wildcard .env)","")
include .env
export $(shell sed 's/=.*//' .env)
endif

# --- Some prep ---

ARGS = `arg="$(filter-out $@,$(MAKECMDGOALS))" && echo $${arg:-${1}}`
DOCKER_RUN_CMD = docker run -it --rm -u $(shell id -u):$(shell id -g) -v ./:/app --workdir="/app" --network="host"

Expand All @@ -11,13 +22,15 @@ devinit:
npm:
$(call DOCKER_RUN_CMD) --entrypoint="npm" node-dev-env:latest $(call ARGS, defaultstring)

pnpm:
$(call DOCKER_RUN_CMD) --entrypoint="pnpm" node-dev-env:latest $(call ARGS, defaultstring)

yarn:
$(call DOCKER_RUN_CMD) --entrypoint="yarn" node-dev-env:latest $(call ARGS, defaultstring)

npx:
$(call DOCKER_RUN_CMD) --entrypoint="npx" node-dev-env:latest $(call ARGS, defaultstring)


nx:
$(call DOCKER_RUN_CMD) --entrypoint="nx" node-dev-env:latest $(call ARGS, defaultstring)

Expand All @@ -26,7 +39,10 @@ node:

# --- Server stuff ---
serve-api:
$(call DOCKER_RUN_CMD) --entrypoint="nx" node-dev-env:latest serve api
$(call DOCKER_RUN_CMD) --entrypoint="nx" node-dev-env:latest serve api --port 8080

serve-platform:
$(call DOCKER_RUN_CMD) --entrypoint="nx" node-dev-env:latest serve platform --verbose
$(call DOCKER_RUN_CMD) --entrypoint="nx" node-dev-env:latest serve platform --port 4200

serve-landing:
$(call DOCKER_RUN_CMD) --entrypoint="nx" node-dev-env:latest serve landing --port 3030
95 changes: 89 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,76 @@



serve-api


# ISOMERA: The Ultimate Javascript/Typescript SaaS Boilerplate Monorepo for Modern Developers

Unlock the future of seamless SaaS development with ISOMERA, the all-encompassing Javascript/Typescript starter boilerplate monorepo. Designed for visionary developers, ISOMERA streamlines the creation of enterprise-grade applications by providing a robust, modular, and scalable foundation. Whether you're kickstarting a project with React, Next, Nest, or diving deep into TypeORM, Redux, and Material UI, our platform is your ticket to efficiency. Beyond a mere boilerplate, ISOMERA offers comprehensive documentation, training materials, and a community-driven approach. Contribute to the revolution, join a community of like-minded developers, and redefine the standards of SaaS development.

Every developer understands the journey: starting with basic functionalities and, over time, integrating advanced features like 2FA, role management, or intricate middleware logic. At the outset, it might seem manageable, but as your project scales and evolves, these additions can accumulate into months of development time. Not to mention the effort spent ensuring earlier work seamlessly integrates with new features. With ISOMERA, this narrative changes. While not every feature on our ToDo list is immediate, our roadmap is designed with foresight. As your project matures, ISOMERA grows with you, offering advanced functionalities just when you need them. It's not just about the initial boost; it's about the cumulative time and effort saved over the life of your project. Dive straight into innovation, knowing the foundational and advanced are already taken care of.

#### 🌟 Join the ISOMERA Revolution as an Open-Source Contributor! 🌟

Are you passionate about shaping the future of SaaS development? Looking for a platform where your expertise can make a real difference? Welcome to ISOMERA! As an open-source project, we believe in the collective genius of the developer community. Your insights, skills, and dedication can help elevate ISOMERA to new heights. Whether you're a seasoned expert or a newcomer eager to learn, there's a space here for you. Dive into our code, collaborate with like-minded innovators, and let's co-create the ultimate Javascript/Typescript boilerplate for the next generation. Join the ISOMERA family and let's craft the future, one line of code at a time. 🚀

## Preview

* Landing page https://www.isomera.org/
* Platform https://app.isomera.org/
* Documentation https://doc.isomera.org/overview.html

## Goals

* Keep this starter project updated and aligned with best practices.
* Produce training materials to simplify your startup process.
* Maintain a streamlined UI, offering flexibility to choose between SCSS, Styled Components, Material UI, or Tailwind for your designs.

## SDLC ToDo

- [ ] Documentation: Getting Started
- [ ] Documentation: Going to Production
- [ ] Training video on how to get started
- [ ] Training video on best practices

## Technical ToDo

- [x] NX monorepo workspace
- [x] Landing page with Next.js
- [ ] CI & Tests
- [ ] Prettier & Linting
- [x] Generated documentation for API with Compodoc
- [ ] Swagger for API endpoints
- [ ] DTO as shared lib
- [ ] Redux-toolkit for app data storage
- [ ] Interfaces as shared lib
- [ ] Utils as shared lib (for example time formatting)
- [ ] TypeORM & DB migrations
- [ ] Plan a strict rules for timestamps (this is frequent problem for projects where users has to interact across multiple timezones)
- [ ] Connect S3 or other object bucket
- [ ] Production Dockerfiles
- [ ] SSL in development
- [ ] Transactional emails and templates (prod/dev)
- [ ] Websockets for notifications and updates
- [ ] GDPR compliance
- [ ] Easy solution for roles and access management
- [ ] SQS queue and jobs - support heavy load
- [ ] Redis & Memcached for caching + tooling in code
- [ ] Production split for api and workers to allow better control on auto-scaling
- [ ] ...

## Features plan

- [ ] User can Sign Up & Sign In using email
- [ ] User can Sign Up & Sign In using Google, Facebook, Apple or Microsoft
- [ ] User can Sign Up & Sign In using phone number (Twillio)
- [ ] User can reset password
- [ ] User can invite other team members to organization (org created for every user, if it's not needed, should be easy to disable or just ignore)
- [ ] User can enter company details to organization (for future billing)
- [ ] User can manage roles for team (OrgOwner, OrgAdmin, OrgManager, OrgFinance, OrgAnalytic, OrgSupport, OrgUser, OrgReadonly, OrgClientVIP, OrgClient)
- [ ] User can transfer organization ownership
- [ ] User can enable 2FA
- [ ] User can enforce 2FA for organization users
- [ ] User can edit basic profile details (name, photo)
- [ ] User can delete organization
- [ ] User can delete account
- [ ] ...

## Developing locally

### Getting started
Expand Down Expand Up @@ -46,12 +113,28 @@ This is pretty simple, just
make nx run-many -- -t test
```

```
make nx run-many -- -t e2e
```

### Running services

#### Run API locally

This will launch API service on port 8080.
This will launch API service on port 8080:

```
make nx serve-api
```

This will launch platform on port 4200:

```
make nx serve-platform
```

This will launch landing on port 3030:

```
make nx serve-landing
```
6 changes: 5 additions & 1 deletion apps/api/src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,17 @@ import { NestFactory } from '@nestjs/core';

import { AppModule } from './app/app.module';

//

async function bootstrap() {
const app = await NestFactory.create(AppModule);
const globalPrefix = 'api';
app.setGlobalPrefix(globalPrefix);
const port = process.env.PORT || 3000;
await app.listen(port);
Logger.log(`🚀 Application is running on: http://localhost:${port}/${globalPrefix}`);
Logger.log(
`🚀 Application is running on: http://localhost:${port}/${globalPrefix}`
);
}

bootstrap();
2 changes: 2 additions & 0 deletions apps/landing/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ export const metadata = {
description: 'Generated by create-nx-workspace',
};

//

export default function RootLayout({
children,
}: {
Expand Down
2 changes: 2 additions & 0 deletions apps/platform/src/app/app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ import NxWelcome from './nx-welcome';

import { Route, Routes, Link } from 'react-router-dom';

//

export function App() {
return (
<div>
Expand Down
4 changes: 4 additions & 0 deletions docker/utility/node.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ FROM node:lts-alpine as builder

WORKDIR /app

ENV PNPM_HOME="/pnpm"
ENV PATH="$PNPM_HOME:$PATH"
RUN corepack enable

RUN yarn global add nx@latest

RUN yarn global add nodemon@latest
Expand Down
Loading

0 comments on commit d96f88e

Please sign in to comment.