@aerogel/cli 0.0.0 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/gel +4 -0
- package/dist/aerogel-cli.d.ts +2 -2
- package/dist/aerogel-cli.js +790 -0
- package/dist/aerogel-cli.js.map +1 -0
- package/package.json +28 -33
- package/src/cli.ts +28 -6
- package/src/commands/Command.ts +14 -9
- package/src/commands/create.test.ts +4 -9
- package/src/commands/create.ts +40 -26
- package/src/commands/generate-component.test.ts +5 -7
- package/src/commands/generate-component.ts +114 -37
- package/src/commands/generate-model.test.ts +17 -6
- package/src/commands/generate-model.ts +47 -22
- package/src/commands/generate-service.test.ts +21 -0
- package/src/commands/generate-service.ts +151 -0
- package/src/commands/info.ts +15 -0
- package/src/commands/install.test.ts +90 -0
- package/src/commands/install.ts +47 -0
- package/src/lib/App.ts +76 -12
- package/src/lib/Editor.ts +57 -0
- package/src/lib/File.mock.ts +13 -11
- package/src/lib/File.ts +43 -3
- package/src/lib/Log.mock.ts +11 -6
- package/src/lib/Log.test.ts +22 -6
- package/src/lib/Log.ts +43 -27
- package/src/lib/Shell.mock.ts +7 -3
- package/src/lib/Shell.ts +2 -2
- package/src/lib/Template.ts +27 -19
- package/src/lib/utils/app.ts +15 -0
- package/src/lib/utils/edit.ts +44 -0
- package/src/lib/utils/paths.ts +46 -0
- package/src/plugins/LocalFirst.ts +9 -0
- package/src/plugins/Plugin.ts +176 -0
- package/src/plugins/Solid.ts +72 -0
- package/src/plugins/Soukai.ts +20 -0
- package/src/testing/setup.ts +62 -25
- package/src/utils/package.ts +23 -0
- package/templates/app/README.md +3 -0
- package/templates/service/[service.name].ts +8 -0
- package/.eslintrc.js +0 -7
- package/bin/ag +0 -4
- package/dist/aerogel-cli.cjs.js +0 -2
- package/dist/aerogel-cli.cjs.js.map +0 -1
- package/dist/aerogel-cli.esm.js +0 -2
- package/dist/aerogel-cli.esm.js.map +0 -1
- package/noeldemartin.config.js +0 -4
- package/src/lib/utils.test.ts +0 -33
- package/src/lib/utils.ts +0 -44
- package/templates/app/.github/workflows/ci.yml +0 -17
- package/templates/app/.nvmrc +0 -1
- package/templates/app/cypress/e2e/app.cy.ts +0 -9
- package/templates/app/cypress/support/e2e.ts +0 -3
- package/templates/app/cypress/tsconfig.json +0 -12
- package/templates/app/cypress.config.ts +0 -8
- package/templates/app/index.html +0 -12
- package/templates/app/package.json +0 -44
- package/templates/app/postcss.config.js +0 -6
- package/templates/app/src/App.vue +0 -10
- package/templates/app/src/assets/styles.css +0 -3
- package/templates/app/src/lang/en.yaml +0 -3
- package/templates/app/src/main.test.ts +0 -9
- package/templates/app/src/main.ts +0 -9
- package/templates/app/src/types/globals.d.ts +0 -3
- package/templates/app/src/types/shims.d.ts +0 -7
- package/templates/app/src/types/ts-reset.d.ts +0 -1
- package/templates/app/tailwind.config.js +0 -5
- package/templates/app/tsconfig.json +0 -18
- package/templates/app/vite.config.ts +0 -21
- package/templates/component-story/[component.name].story.vue +0 -7
- package/tsconfig.json +0 -11
- package/vite.config.ts +0 -14
- /package/src/{main.ts → index.ts} +0 -0
package/templates/app/index.html
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html>
|
|
2
|
-
<html lang="en" class="h-full w-full">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="UTF-8" />
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
-
<title><% app.name %></title>
|
|
7
|
-
</head>
|
|
8
|
-
<body class="h-full w-full">
|
|
9
|
-
<div id="app" class="h-full"></div>
|
|
10
|
-
<script type="module" src="./src/main.ts"></script>
|
|
11
|
-
</body>
|
|
12
|
-
</html>
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "<% app.slug %>",
|
|
3
|
-
"version": "0.0.0",
|
|
4
|
-
"private": true,
|
|
5
|
-
"scripts": {
|
|
6
|
-
"build": "vite build",
|
|
7
|
-
"cy:dev": "concurrently --kill-others \"npm run test:serve-app\" \"npm run cy:open\"",
|
|
8
|
-
"cy:open": "cypress open --e2e --browser chromium",
|
|
9
|
-
"cy:run": "cypress run",
|
|
10
|
-
"cy:test": "start-server-and-test test:serve-app http-get://localhost:5001 cy:run",
|
|
11
|
-
"dev": "vite",
|
|
12
|
-
"lint": "noeldemartin-lint src",
|
|
13
|
-
"test": "vitest --run",
|
|
14
|
-
"test:ci": "vitest --run --reporter verbose",
|
|
15
|
-
"test:serve-app": "vite --port 5001"
|
|
16
|
-
},
|
|
17
|
-
"dependencies": {
|
|
18
|
-
"@aerogel/core": "next",
|
|
19
|
-
"@aerogel/plugin-i18n": "next",
|
|
20
|
-
"@intlify/unplugin-vue-i18n": "^0.12.2",
|
|
21
|
-
"@tailwindcss/forms": "^0.5.3",
|
|
22
|
-
"@tailwindcss/typography": "^0.5.9",
|
|
23
|
-
"soukai": "^0.5.1",
|
|
24
|
-
"tailwindcss": "^3.3.2",
|
|
25
|
-
"vue": "^3.3.0",
|
|
26
|
-
"vue-i18n": "9.3.0-beta.19",
|
|
27
|
-
"vue-router": "^4.2.1"
|
|
28
|
-
},
|
|
29
|
-
"devDependencies": {
|
|
30
|
-
"@aerogel/cli": "next",
|
|
31
|
-
"@aerogel/cypress": "next",
|
|
32
|
-
"@aerogel/vite": "next",
|
|
33
|
-
"@noeldemartin/utils": "0.4.0-next.ac00beaecf32bb02ed8e335225d7948d946d73bd",
|
|
34
|
-
"@total-typescript/ts-reset": "^0.4.2",
|
|
35
|
-
"@types/node": "^20.3.1",
|
|
36
|
-
"autoprefixer": "^10.4.14",
|
|
37
|
-
"concurrently": "^8.2.0",
|
|
38
|
-
"cypress": "^12.17.0",
|
|
39
|
-
"start-server-and-test": "^2.0.0",
|
|
40
|
-
"unplugin-vue-components": "^0.24.1",
|
|
41
|
-
"vite": "^4.3.0",
|
|
42
|
-
"vitest": "^0.33.0"
|
|
43
|
-
}
|
|
44
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<AGAppLayout>
|
|
3
|
-
<main class="flex flex-grow flex-col items-center justify-center bg-blue-50">
|
|
4
|
-
<h1 class="text-4xl font-semibold">{{ $t('home.title') }}</h1>
|
|
5
|
-
<a href="https://aerogel.js.org" target="_blank" class="mt-2 underline opacity-75 hover:opacity-100">
|
|
6
|
-
{{ $t('home.getStarted') }}
|
|
7
|
-
</a>
|
|
8
|
-
</main>
|
|
9
|
-
</AGAppLayout>
|
|
10
|
-
</template>
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import i18n from '@aerogel/plugin-i18n';
|
|
2
|
-
import { bootstrapApplication } from '@aerogel/core';
|
|
3
|
-
|
|
4
|
-
import './assets/styles.css';
|
|
5
|
-
import App from './App.vue';
|
|
6
|
-
|
|
7
|
-
bootstrapApplication(App, {
|
|
8
|
-
plugins: [i18n({ messages: import.meta.glob('@/lang/*.yaml') })],
|
|
9
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
/// <reference types="@total-typescript/ts-reset" />
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compilerOptions": {
|
|
3
|
-
"target": "esnext",
|
|
4
|
-
"module": "esnext",
|
|
5
|
-
"moduleResolution": "node",
|
|
6
|
-
"strict": true,
|
|
7
|
-
"jsx": "preserve",
|
|
8
|
-
"noUncheckedIndexedAccess": true,
|
|
9
|
-
"resolveJsonModule": true,
|
|
10
|
-
"esModuleInterop": true,
|
|
11
|
-
"lib": ["esnext", "dom"],
|
|
12
|
-
"baseUrl": ".",
|
|
13
|
-
"paths": {
|
|
14
|
-
"@/*": ["./src/*"]
|
|
15
|
-
}
|
|
16
|
-
},
|
|
17
|
-
"include": ["src/**/*.ts", "src/**/*.vue"]
|
|
18
|
-
}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import Aerogel, { AerogelResolver } from '@aerogel/vite';
|
|
2
|
-
import Components from 'unplugin-vue-components/vite';
|
|
3
|
-
import I18n from '@intlify/unplugin-vue-i18n/vite';
|
|
4
|
-
import { resolve } from 'path';
|
|
5
|
-
|
|
6
|
-
export default {
|
|
7
|
-
plugins: [
|
|
8
|
-
I18n({ include: resolve(__dirname, './src/lang/**/*.yaml') }),
|
|
9
|
-
Aerogel(),
|
|
10
|
-
Components({
|
|
11
|
-
dirs: ['src/pages'],
|
|
12
|
-
dts: false,
|
|
13
|
-
resolvers: [AerogelResolver()],
|
|
14
|
-
}),
|
|
15
|
-
],
|
|
16
|
-
resolve: {
|
|
17
|
-
alias: {
|
|
18
|
-
'@': resolve(__dirname, './src'),
|
|
19
|
-
},
|
|
20
|
-
},
|
|
21
|
-
};
|
package/tsconfig.json
DELETED
package/vite.config.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { defineConfig } from 'vitest/config';
|
|
2
|
-
import { resolve } from 'path';
|
|
3
|
-
|
|
4
|
-
export default defineConfig({
|
|
5
|
-
test: {
|
|
6
|
-
clearMocks: true,
|
|
7
|
-
setupFiles: ['./src/testing/setup.ts'],
|
|
8
|
-
},
|
|
9
|
-
resolve: {
|
|
10
|
-
alias: {
|
|
11
|
-
'@': resolve(__dirname, './src'),
|
|
12
|
-
},
|
|
13
|
-
},
|
|
14
|
-
});
|
|
File without changes
|