โฉ Nest + Prisma + Apollo + Angular ๐ฎ Full Stack GraphQL Starter Kit โฉ
Bot releases are hidden (Show)
Published by ZenSoftware 4 months ago
ng generate @angular/material:m3-theme
and integrated a basic light and dark theme for the repo. The themes are directly importing the SASS styles and can be tweaked to your own taste under the theme
folder.apps/api/src/app/graphql/resolvers/prisma
and regenerate them. You may keep the User.ts
resolver file as it already has been regenerated for you. No other significant changes should be needed if you've managed to merge all the other changes successfully.@Input() sortable: SortSettings = { mode: 'multiple' };
instead of single
.kendo
branch now has working filtering for Prisma's Filter on "-to-one" relations. This will allow you to have columns within the grid that can now be filtered over with nested objects. As an example:apps/api/prisma/schema.prisma
model User {
id String @id @default(uuid())
...
address Address? @relation(fields: [addressId], references: [id])
addressId String?
}
model Address {
id String @id @default(uuid())
country String?
...
User User[]
}
libs/graphql/src/lib/fields/User.gql.ts
import gql from 'graphql-tag';
import { AddressFields } from './Address.gql';
export const UserFields = gql`
fragment UserFields on User {
id
address {
...AddressFields
}
}
${AddressFields}
`;
libs/main/src/lib/zen-portal/zen-super/zen-user-manager/zen-user-grid/zen-user-grid.component.ts
const DEFAULT_SETTINGS: KendoGridSettings<UserFields> = {
columnsConfig: [
{
field: 'address.country',
title: 'Country',
filter: 'text',
custom: { nullable: true },
},
],
};
Published by ZenSoftware 8 months ago
README.md
files of the project to describe what is included and provided instructions on how to get your development environment setup and compile the Unity WebGL project.This project is rock-solid with now more than 3 years of refinement. It combines the best libraries I could possibly find within the ecosystems that this project is utilizing. The starter kit is highly robust with hyper lean implementations. git merge
in whichever features you need for any particular project and git pull
in changes from this repo for your own git clone
of this repo to keep your own projects up to date with the latest updates.
Published by ZenSoftware 11 months ago
ngIf
and ngFor
structural directives to Angular's new control flow syntax.loggedIn
and userRoles
fields within AuthService
have been changed from Angular signals to rxjs observables. This change was necessary to update to Angular v17.Published by ZenSoftware 12 months ago
count
in their latest release. This requires deleting and regenerating the Nest GraphQL resolvers under apps/api/src/app/graphql/resolvers/prisma
. The User
GraphQL resolvers can be kept as the changes have been pushed to the repository.Published by ZenSoftware 12 months ago
Published by ZenSoftware about 1 year ago
apps/api/src/environments/environment.ts
and environment.prod.ts
have changed the throttle
option to utilize the updated ThrottlerModuleOptions
.Published by ZenSoftware about 1 year ago
Pal.Js v6.0.5 has resolved the issues that blocked us from upgrading to Prisma v5. The code generating templates have been updated. Resolvers under apps/api/src/app/graphql/resolvers/prisma
can be deleted and regenerated. Though, the User.ts
resolver can be kept as it has been regenerated and committed to the repo.
Published by ZenSoftware about 1 year ago
Updated all dependencies we are not blocked on. Notably the largest change is an upgrade to Pal.Js v6. Code generation scripts have been adapted to accommodate for the changes.
Published by ZenSoftware over 1 year ago
๐ This major release completes many large milestones. There has been a refactor across the project to consolidate code into fewer libraries and a new project structure that is more organized to enable better management of domain assets. There is much more clarity of where things belong and there is a better conceptual model for consumers of core libraries. The new default configurations that come out of the box should be sufficient for the majority of projects.
The starter kit is now in a pristine state and the solutions provided are feature complete. Nearly every line of code has been reviewed and rewrites have been done across the project for cleaner and leaner solutions.
Furthermore, debugging with VSCode works well for both the api
(Nest) and portal
(Angular) apps. There have been problems within the Nx community with not having breakpoints working. Fortunately, there are workarounds that this project implements to ensure everything is operating as expected.
The project dependencies have been updated to the latest version across the board. We are not blocked from updating to the latest version for almost any of our dependencies. We're riding on the bleeding edge of all solutions available.
Noteable updates for this version include:
apollo-angular
updated to v5.0.0@graphql-codegen/cli
has been updated to v4.0.1๐ The kendo
branch has integrated new features.
prisma
subfolder within the GraphQL resolvers
folder.RBAC
for the code generating script at tools/generate.ts
.@casl/prisma
integration is marked as experimental but its integration is kept as the project's solution for ABAC
and is still feature complete.@zen/layout
to @zen/components
and @zen/layout
has been removed.@zen/auth
has had a major overhaul for all its Angular components to make everything more reusable.Published by ZenSoftware over 1 year ago
AuthService
userRoles
& loggedIn
fields are now Angular signalsPublished by ZenSoftware over 1 year ago
This major release contains a complete overhaul for authorization. A lot of thought went into creating a more maintainable authorization scheme. View @zen/nest-auth README.md for documentation. Previously there were specific guards & decorators depending on whether they were being applied to HTTP or GraphQL contexts. These have all been reconciled into guards & decorators that work for both contexts. For example, @GqlUser
& @HttpUser
have been replaced with @CurrentUser
.
Furthermore, the code generation of the GraphQL resolvers for the Prisma CRUD endpoints have been rewritten to properly implement @casl/prisma
. It required some experience with the library to really work out how to best integrated CASL into the api. Authorization is in a much better place for this release.
package.json
with a fine tooth comb and removed all unnecessary dependencies.@angular/material
v15.class-validator
not playing well with it.id
field is now a String @default(uuid())
instead of Int @default(autoincrement())
.kendo
branch has been updated to the newest release of Kendo v11.otel
branch now integrates Prisma tracing.404 Page not found
component for the Angular app.@zen/api-interfaces
library and consolidated everything under @zen/common
.@zen/auth
& @zen/components
libraries. This allows for a simple way to browse the catalogue of components available.Published by ZenSoftware almost 2 years ago
@casl/angular
& @casl/prisma
There was a need for a major refactoring of the project to convert it from a monolith into something much more modular. One in which multiple Nx apps could be backed by their own respective databases. Housing their own schema.prisma
file under apps/<APP_NAME>/schema.prisma
, rather than a single prisma/schema.prisma
file existing at the root.
nest-auth
in which multiple Nest apps could importtools
casl-prisma.ts
apps/portal/src/app/app.module.ts
Published by ZenSoftware about 2 years ago
@nest-modules/mailer
with @nestjs-modules/mailer
https://github.com/ZenSoftware/zen/issues/22
@AllowAnonymous
decorator the imitates ASP.NET Core AllowAnonymous attribute
Published by ZenSoftware over 2 years ago
@nestjs/passport
main
to base
. This project is intended to be a base for several forked projects. Duplicate branch names are not allowed, so we do not want to take up the main
branch name. Forked projects can keep their projects up to date with the latest version of this repo by adding this repo as a remote, pulling changes, and then merging base
into their own main
branch.vX.X.X
to zX.X.X
to not occupy conventional semantic versioning tags of forked projects.Login
link on /login
page.userId
in AuthService
.<zen-layout>
Published by ZenSoftware over 2 years ago
BREAKING CHANGE: Renamed RejectNestedCreateGuard to ForbidNestedCreateGuard
Published by ZenSoftware over 2 years ago
Published by ZenSoftware over 2 years ago
@zen/auth
to clean up codePublished by ZenSoftware over 2 years ago
graphql-ws
. The starter kit is now converted to utilize the newer library as a substitute for the older library subscriptions-transport-ws
.Published by ZenSoftware over 2 years ago
Published by ZenSoftware over 2 years ago