-
-
Notifications
You must be signed in to change notification settings - Fork 414
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migrate to NPM and cleanup Playground (#1951)
This Pull Request closes #1912 by migrating to a NPM based build, hopefully making it easier to contribute to the Playground. Also, reduces the number of features of the editor, since most of them were support for other languages or features that don't make sense in a playground environment. This considerably reduces the number of fetched files per page load and the total size of the playground.
- Loading branch information
Showing
11 changed files
with
8,557 additions
and
2,913 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,10 +23,11 @@ jobs: | |
- uses: actions/checkout@v3 | ||
- name: Install wasm-pack | ||
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh | ||
- uses: Borales/actions[email protected] | ||
- uses: actions/setup-node@v3 | ||
with: | ||
cmd: install | ||
- name: Cache yarn build | ||
node-version: "16" | ||
- run: npm ci | ||
- name: Cache npm build | ||
uses: actions/[email protected] | ||
with: | ||
path: | | ||
|
@@ -35,10 +36,8 @@ jobs: | |
boa_wasm/pkg | ||
~/.cargo/git | ||
~/.cargo/registry | ||
key: ${{ runner.os }}-yarn-build-target-${{ hashFiles('**/yarn.lock') }} | ||
- uses: Borales/[email protected] | ||
with: | ||
cmd: build:prod | ||
key: ${{ runner.os }}-npm-build-target-${{ hashFiles('**/package-lock.json') }} | ||
- run: npm run build:prod | ||
- name: Deploy | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -32,7 +32,7 @@ jobs: | |
profile: minimal | ||
- name: Install wasm-pack | ||
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh | ||
- name: Cache yarn build | ||
- name: Cache npm build | ||
uses: actions/[email protected] | ||
with: | ||
path: | | ||
|
@@ -41,10 +41,9 @@ jobs: | |
~/.cargo/git | ||
~/.cargo/registry | ||
boa_wasm/pkg | ||
key: ${{ runner.os }}-yarn-build-target-${{ hashFiles('**/yarn.lock') }} | ||
- uses: Borales/actions[email protected] | ||
key: ${{ runner.os }}-npm-build-target-${{ hashFiles('**/package-lock.json') }} | ||
- uses: actions/setup-node@v3 | ||
with: | ||
cmd: install | ||
- uses: Borales/[email protected] | ||
with: | ||
cmd: build | ||
node-version: "16" | ||
- run: npm ci | ||
- run: npm run build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,6 +11,7 @@ | |
display: flex; | ||
align-items: center; | ||
} | ||
|
||
.demo__img { | ||
width: 170px; | ||
display: block; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.