Skip to content

Commit

Permalink
feat: deploy svelte and angular apps
Browse files Browse the repository at this point in the history
  • Loading branch information
davidecarpini committed Nov 23, 2023
1 parent f44c061 commit ac046b6
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/deploy-gh-pages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ jobs:
cp -r apps/sample-react-app/build build/react
cp -r apps/sample-vanilla-app/dist build/vanilla
cp -r apps/sample-svelte-app/dist build/svelte
cp -r apps/sample-angular-app/dist build/angular
cp -r apps/sample-angular-app/dist/easy-angular build/angular
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
Expand Down
3 changes: 1 addition & 2 deletions apps/sample-angular-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,9 @@
"private": true,
"scripts": {
"add-page": "ng g m pages/page-name --routing && ng g component pages/page-name --skip-tests",
"build": "ng build --configuration development",
"dev": "ng serve",
"lint": "eslint src --ext .js,.jsx,.ts,.tsx",
"ng": "ng",
"test": "ng test",
"watch": "ng build --watch --configuration development"
},
"dependencies": {
Expand Down
1 change: 1 addition & 0 deletions apps/sample-svelte-app/.eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,4 @@ node_modules
pnpm-lock.yaml
package-lock.json
yarn.lock
.eslintrc.cjs
8 changes: 8 additions & 0 deletions apps/sample-svelte-app/.eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
const Config = require('@vechain/repo-config');

module.exports = {
...Config.EslintLibrary,
rules: {
'no-constant-binary-expression': 'off',
},
};
1 change: 1 addition & 0 deletions apps/sample-svelte-app/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.eslintrc.js
4 changes: 3 additions & 1 deletion apps/sample-svelte-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
"type": "module",
"scripts": {
"build": "vite build",
"dev": "vite dev"
"dev": "vite dev",
"lint": "eslint src --ext .js,.jsx,.ts,.tsx"
},
"dependencies": {
"@vechainfoundation/dapp-kit-ui": "*",
Expand All @@ -17,6 +18,7 @@
"@esbuild-plugins/node-globals-polyfill": "^0.2.3",
"@esbuild-plugins/node-modules-polyfill": "^0.2.2",
"@sveltejs/adapter-auto": "^2.0.0",
"@sveltejs/adapter-static": "^2.0.3",
"@sveltejs/kit": "^1.27.4",
"@typescript-eslint/eslint-plugin": "^6.0.0",
"@typescript-eslint/parser": "^6.0.0",
Expand Down
1 change: 1 addition & 0 deletions apps/sample-svelte-app/src/routes/+layout.js
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
export const ssr = false;
export const prerender = true;
12 changes: 10 additions & 2 deletions apps/sample-svelte-app/svelte.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import adapter from '@sveltejs/adapter-auto';
import adapter from '@sveltejs/adapter-static';
import { vitePreprocess } from '@sveltejs/kit/vite';

/** @type {import('@sveltejs/kit').Config} */
Expand All @@ -11,7 +11,15 @@ const config = {
// adapter-auto only supports some environments, see https://kit.svelte.dev/docs/adapter-auto for a list.
// If your environment is not supported or you settled on a specific environment, switch out the adapter.
// See https://kit.svelte.dev/docs/adapters for more information about adapters.
adapter: adapter(),
adapter: adapter({
// default options are shown. On some platforms
// these options are set automatically — see below
pages: 'dist',
assets: 'dist',
fallback: undefined,
precompress: false,
strict: true,
}),
},
};

Expand Down

0 comments on commit ac046b6

Please sign in to comment.