Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TASK] Migrate to Vite #46

Merged
merged 6 commits into from
Oct 10, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/build
/dev-dist
14 changes: 0 additions & 14 deletions .eslintrc

This file was deleted.

17 changes: 17 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"root": true,
"parserOptions": {
"sourceType": "module"
},
"env": {
"browser": true,
"es2020": true,
"node": true
},
"extends": ["eslint:recommended", "prettier"],
"rules": {
"no-undef": "off",
"no-prototype-builtins": "off",
"no-useless-escape": "off"
}
}
18 changes: 13 additions & 5 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -1,42 +1,50 @@
---
name: Bug report
about: Create a report to help us improve the software

---

<!-- Provide a general summary of the issue in the title above -->
<!-- This template should help to improve the report, unneeded parts can be removed -->
<!-- Everything between these comment tags is hidden from the issue and just there to guide you. -->

## Expected Behavior

<!-- If you're describing a bug, tell us what should happen -->
<!-- If you're suggesting a change/improvement, tell us how it should work -->

## Current Behavior

<!-- If describing a bug, tell us what happens instead of the expected behavior -->
<!-- If suggesting a change/improvement, explain the difference from current behavior -->

## Possible Solution

<!-- Not obligatory, but suggest a fix/reason for the bug, or ideas how to implement the addition or change -->

## Steps to Reproduce

<!-- Provide a link to a live example, or an unambiguous set of steps to reproduce this bug. -->
<!-- Include code to reproduce, if relevant -->

1.
2.
3.
4.

## Context

<!-- How has this issue affected you? What are you trying to accomplish? -->
<!-- Providing context helps us come up with a solution that is most useful in the real world -->

## Your Environment

<!-- Include as many relevant details about the environment you experienced the bug in -->
* Version used: ``
* Browser Name and version: ``
* Operating System and version (desktop or mobile): ``
* Link to your project: ``

- Version used: ``
- Browser Name and version: ``
- Operating System and version (desktop or mobile): ``
- Link to your project: ``

## Screenshots

<!-- If applicable, add screenshots to help explain your problem. -->
5 changes: 4 additions & 1 deletion .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -1,21 +1,24 @@
---
name: Feature request
about: Suggest an idea for this project

---

<!-- Provide a general summary of the issue in the Title above -->
<!-- This template should help to improve the report, unneeded parts can be removed -->
<!-- Everything between these comment tags is hidden from the issue and just there to guide you. -->

## Is your feature request related to a problem? Please describe.

<!-- A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] -->

## Describe the solution you'd like

<!-- A clear and concise description of what you want to happen. -->

## Describe alternatives you've considered

<!-- A clear and concise description of any alternative solutions or features you've considered. -->

## Additional context

<!-- Add any other context or screenshots about the feature request here. -->
6 changes: 6 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,28 @@
<!-- Everything between these comment tags is hidden from the issue and just there to guide you. -->

## Description

<!-- Describe your changes -->

## Motivation and Context

<!-- Why is this change required? What problem does it solve? -->
<!-- If it fixes an open issue, please link to the issue here. -->

## How Has This Been Tested?

<!-- Please try to test the code in multiple browsers and on a mobile device -->

## Screenshots/links:

<!-- Add screenshots of changed code if visual output has changed / is more complex. -->
<!-- Include both before and after screenshots to easily compare and discuss changes when available. -->

## Checklist:

<!-- Go over all the following points, and put an `x` in all the boxes that apply. -->
<!-- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->

- [ ] My code follows the code style of this project. (CI will test it anyway and also needs approval)
- [ ] My change requires a change to the documentation.
- [ ] I have updated the documentation accordingly.
17 changes: 9 additions & 8 deletions .github/workflows/build-meshviewer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,12 @@ jobs:
matrix:
node-version: [20.x]
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm audit
- run: npm run gulp-ci
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm audit
- run: npm run lint
- run: npm run build
58 changes: 29 additions & 29 deletions .github/workflows/release-meshviewer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,39 +3,39 @@ on:
push:
# Sequence of patterns matched against refs/tags
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
- "v*" # Push events to matching v*, i.e. v1.0, v20.15.10
jobs:
meshviewer-release:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20.x]
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm run gulp
- run: "cd build; zip -r ../meshviewer-build.zip .; cd .."
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: true
prerelease: false
- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./meshviewer-build.zip
asset_name: meshviewer-build.zip
asset_content_type: application/zip
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm run build
- run: "cd build; zip -r ../meshviewer-build.zip .; cd .."
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: true
prerelease: false
- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./meshviewer-build.zip
asset_name: meshviewer-build.zip
asset_content_type: application/zip
10 changes: 6 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,12 @@
Thumbs.db

# IDE files
/.idea/
/.idea

# Project files
node_modules/
build/
config.js
/node_modules
/build
/config.js
*.zip
/dev-dist
/public/config.json
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/build
/dev-dist
3 changes: 3 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"printWidth": 120
}
9 changes: 6 additions & 3 deletions .stylelintrc
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
{
"extends": "stylelint-config-standard",
"rules": {
"at-rule-no-unknown": [true, {
"ignoreAtRules": ["function", "if", "each", "include", "mixin"]
}],
"at-rule-no-unknown": [
true,
{
"ignoreAtRules": ["function", "if", "each", "include", "mixin"]
}
],
"number-leading-zero": "never",
"no-descending-specificity": null
}
Expand Down
Loading