Skip to content

Commit

Permalink
create @primate/angular
Browse files Browse the repository at this point in the history
  • Loading branch information
terrablue committed Aug 4, 2024
1 parent 2c0a6c3 commit d8fa21d
Show file tree
Hide file tree
Showing 19 changed files with 74 additions and 52 deletions.
50 changes: 50 additions & 0 deletions packages/angular/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{
"name": "@primate/angular",
"version": "0.1.0",
"description": "Primate Angular frontend",
"bugs": "https://github.com/primatejs/primate/issues",
"license": "MIT",
"files": [
"src/**/*.js",
"!src/**/*.spec.js"
],
"repository": {
"type": "git",
"url": "https://github.com/primatejs/primate",
"directory": "packages/angular"
},
"dependencies": {
"@angular/compiler": "18",
"@angular/core": "18",
"@angular/platform-browser": "18",
"@angular/platform-server": "18",
"@angular/ssr": "18",
"@primate/core": "workspace:^",
"zone.js": "0.14"
},
"peerDependencies": {
"vue": "3",
"primate": "workspace:^"
},
"type": "module",
"imports": {
"#*": {
"@primate/lt": "./src/private/*.js",
"default": "./src/private/*.js"
},
"#build": {
"@primate/lt": "./src/private/build/index.js",
"default": "./src/private/build/index.js"
},
"#serve": {
"@primate/lt": "./src/private/serve/index.js",
"default": "./src/private/serve/index.js"
}
},
"exports": {
".": {
"runtime": "./src/public/runtime.js",
"default": "./src/public/default.js"
}
}
}
File renamed without changes.
File renamed without changes.
1 change: 1 addition & 0 deletions packages/angular/src/private/pkgname.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default "@primate/angular";
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import serve from "#serve";
import serve from "@primate/frontend/core/serve";
import render from "./render.js";
import set_mode from "./set-mode.js";

Expand Down
10 changes: 10 additions & 0 deletions packages/angular/src/public/default.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import build from "#build";
import default_extension from "#extension";
import pkgname from "#pkgname";
import serve from "#serve";

export default ({ extension = default_extension } = {}) => ({
name: pkgname,
build: build(extension),
serve: serve(extension),
});
8 changes: 8 additions & 0 deletions packages/angular/src/public/runtime.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import default_extension from "#extension";
import pkgname from "#pkgname";
import serve from "#serve";

export default ({ extension = default_extension } = {}) => ({
name: pkgname,
serve: serve(extension),
});
3 changes: 3 additions & 0 deletions packages/angular/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"extends": "../../tsconfig.base.json"
}
26 changes: 1 addition & 25 deletions packages/frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,37 +24,16 @@
"@rcompat/object": "^0.5.0"
},
"peerDependencies": {
"@angular/compiler": "18",
"@angular/core": "18",
"@angular/platform-browser": "18",
"@angular/platform-server": "18",
"@angular/ssr": "18",
"@babel/core": "7",
"babel-preset-solid": "1",
"htmx-esm": "0.2",
"primate": "workspace:^",
"react": "18",
"react-dom": "18",
"solid-js": "1",
"svelte": "4",
"zone.js": "0.14"
"svelte": "4"
},
"peerDependenciesMeta": {
"@angular/compiler": {
"optional": true
},
"@angular/core": {
"optional": true
},
"@angular/platform-browser": {
"optional": true
},
"@angular/platform-server": {
"optional": true
},
"@angular/ssr": {
"optional": true
},
"@babel/core": {
"optional": true
},
Expand All @@ -75,9 +54,6 @@
},
"svelte": {
"optional": true
},
"zone.js": {
"optional": true
}
},
"type": "module",
Expand Down
7 changes: 0 additions & 7 deletions packages/frontend/src/server/angular/dependencies.js

This file was deleted.

1 change: 0 additions & 1 deletion packages/frontend/src/server/angular/name.js

This file was deleted.

10 changes: 0 additions & 10 deletions packages/frontend/src/server/angular/public/default.js

This file was deleted.

8 changes: 0 additions & 8 deletions packages/frontend/src/server/angular/public/runtime.js

This file was deleted.

0 comments on commit d8fa21d

Please sign in to comment.