Skip to content

Commit

Permalink
Importing frontend code into the sdk
Browse files Browse the repository at this point in the history
  • Loading branch information
epifab committed Feb 27, 2024
1 parent ecc9bdf commit abe3c7d
Show file tree
Hide file tree
Showing 37 changed files with 658 additions and 26,678 deletions.
19 changes: 12 additions & 7 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,20 @@ jobs:
- name: Setup NPM
uses: actions/setup-node@v4
with:
node-version: 12
node-version: 18
- name: Build
run: sbt frontend/fastOptJS/webpack
- name: Prepare artifact
run: |
mkdir artifact
cp modules/frontend/target/scala-3.3.1/frontend-fastopt/main.js artifact/main.js
cp -r modules/backend/src/main/resources/static artifact/static
cp modules/backend/src/main/resources/index.html artifact/index.html
sbt test sdk/fullLinkJS
cp modules/sdk/target/scala-3.3.1/sdk-opt/main.js modules/sdk/src/main/typescript/index.js
cd modules/sdk/src/main/typescript
npm install
find model -name "*-ti.ts" -type f -delete
`npm bin`/ts-interface-builder model/*.ts
npm link
cd ../../../../../frontend
npm install
npm link bastoni
npm run build
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
Expand Down
18 changes: 18 additions & 0 deletions frontend/.eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
module.exports = {
root: true,
env: { browser: true, es2020: true },
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:react-hooks/recommended',
],
ignorePatterns: ['dist', '.eslintrc.cjs'],
parser: '@typescript-eslint/parser',
plugins: ['react-refresh'],
rules: {
'react-refresh/only-export-components': [
'warn',
{ allowConstantExport: true },
],
},
}
Loading

0 comments on commit abe3c7d

Please sign in to comment.