Skip to content

Commit

Permalink
Merge branch 'main' of ssh://github.com/BuilderIO/qwik into allow_jsx…
Browse files Browse the repository at this point in the history
…node_to_serialize
  • Loading branch information
genki committed Feb 22, 2024
2 parents 09e12e7 + a03a2f9 commit 6d67d21
Show file tree
Hide file tree
Showing 512 changed files with 11,617 additions and 6,615 deletions.
16 changes: 8 additions & 8 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
{
"name": "Qwik devcontainer",
"hostRequirements": {
"cpus": 4
"cpus": 4,
},
// Add the IDs of extensions you want installed when the container is created.
"extensions": [
Expand All @@ -15,23 +15,23 @@
"ms-azuretools.vscode-docker",
"mitsuhiko.insta",
"silvenon.mdx",
"csstools.postcss"
"csstools.postcss",
],
"build": {
"dockerfile": "Dockerfile"
"dockerfile": "Dockerfile",
},
"waitFor": "updateContentCommand",
"updateContentCommand": "corepack prepare & pnpm install",
"forwardPorts": [3300, 9229],
"customizations": {
"codespaces": {
"openFiles": ["CONTRIBUTING.md"]
}
"openFiles": ["CONTRIBUTING.md"],
},
},
"portsAttributes": {
"3300": {
"label": "Serve",
"onAutoForward": "openPreview"
}
}
"onAutoForward": "openPreview",
},
},
}
2 changes: 2 additions & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
use flake
PATH_add ./node_modules/.bin
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ scripts/**/*
**/server/**/*.js
*.tsbuildinfo
packages/docs/api/**/*
packages/docs/public/repl/bundled/**/*
packages/docs/src/routes/examples/apps/**/*
packages/docs/src/routes/playground/app/**/*
packages/docs/src/routes/tutorial/**/*
Expand Down
15 changes: 13 additions & 2 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,24 @@ module.exports = {
es2021: true,
node: true,
},
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended'],
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
// Enable this for testing but it makes the lint quite slow
// 'plugin:qwik/recommended',
],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 12,
sourceType: 'module',
// Needed when using the qwik plugin
// project: ['./tsconfig.json'],
},
plugins: ['@typescript-eslint', 'no-only-tests'],
plugins: [
'@typescript-eslint',
'no-only-tests',
// 'qwik'
],
rules: {
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
Expand Down
84 changes: 57 additions & 27 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,16 +109,19 @@ jobs:
- run: corepack enable

- name: Install NPM Dependencies
run: pnpm install --frozen-lockfile
run: |
# Ensure that the qwik binary gets made
mkdir -p packages/qwik/dist/bindings/
pnpm install --frozen-lockfile
- name: Build Packages
run: pnpm tsm scripts/index.ts --tsc --build --cli --api --set-dist-tag="${{ github.event.inputs.disttag }}"
run: pnpm tsm scripts/index.ts --tsc --build --cli --api --qwiklabs --eslint --platform-binding-wasm-copy --set-dist-tag="${{ github.event.inputs.disttag }}"

- name: Print Qwik Dist Build
run: tree packages/qwik/dist/

- name: Upload Qwik Build Artifacts
uses: actions/upload-artifact@master
uses: actions/upload-artifact@v3
with:
name: dist-dev-builder-io-qwik
path: packages/qwik/dist/
Expand All @@ -128,7 +131,7 @@ jobs:
run: tree packages/create-qwik/dist/

- name: Upload Create Qwik CLI Build Artifacts
uses: actions/upload-artifact@master
uses: actions/upload-artifact@v3
with:
name: dist-dev-create-qwik
path: packages/create-qwik/dist/
Expand All @@ -141,7 +144,7 @@ jobs:
run: tree packages/eslint-plugin-qwik/dist/

- name: Upload Eslint rules Build Artifacts
uses: actions/upload-artifact@master
uses: actions/upload-artifact@v3
with:
name: dist-dev-eslint-plugin-qwik
path: packages/eslint-plugin-qwik/dist/
Expand Down Expand Up @@ -203,7 +206,10 @@ jobs:

- name: Install NPM Dependencies
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
run: pnpm install --frozen-lockfile
run: |
# Ensure that the qwik binary gets made
mkdir -p packages/qwik/dist/bindings/
pnpm install --frozen-lockfile
- uses: jetli/wasm-pack-action@v0.3.0
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
Expand All @@ -220,7 +226,7 @@ jobs:

- name: Upload WASM Build Artifacts
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
uses: actions/upload-artifact@master
uses: actions/upload-artifact@v3
with:
name: dist-bindings-wasm
path: packages/qwik/dist/bindings/*
Expand Down Expand Up @@ -311,7 +317,10 @@ jobs:

- name: Install NPM Dependencies
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
run: pnpm install --frozen-lockfile
run: |
# Ensure that the qwik binary gets made
mkdir -p packages/qwik/dist/bindings/
pnpm install --frozen-lockfile
- name: Build Platform Binding
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
Expand Down Expand Up @@ -350,12 +359,14 @@ jobs:

- name: Install NPM Dependencies
if: ${{ needs.changes.outputs.insightsbuild == 'true' }}
run: pnpm install --frozen-lockfile
run: |
# Ensure that the qwik binary gets made
mkdir -p packages/qwik/dist/bindings/
pnpm install --frozen-lockfile
- name: Build Qwik Insights
if: ${{ needs.changes.outputs.insightsbuild == 'true' }}
working-directory: packages/insights
run: pnpm run build.ci
run: pnpm run build.packages.insights

############ BUILD DOCS ############
build-docs:
Expand All @@ -381,12 +392,14 @@ jobs:

- name: Install NPM Dependencies
if: ${{ needs.changes.outputs.docsbuild == 'true' }}
run: pnpm install --frozen-lockfile
run: |
# Ensure that the qwik binary gets made
mkdir -p packages/qwik/dist/bindings/
pnpm install --frozen-lockfile
- name: Build Qwik Docs
if: ${{ needs.changes.outputs.docsbuild == 'true' }}
working-directory: packages/docs
run: pnpm run build
run: pnpm run build.packages.docs

############ BUILD DISTRIBUTION ############
build-distribution:
Expand Down Expand Up @@ -421,13 +434,11 @@ jobs:
if: ${{ needs.changes.outputs.fullbuild == 'true' }}

- name: Install NPM Dependencies
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
run: pnpm install --frozen-lockfile

- name: Create packages/qwik/dist/ directory
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
run: |
# Ensure that the qwik binary gets made
mkdir -p packages/qwik/dist/bindings/
pnpm install --frozen-lockfile
- name: Download Build Artifacts
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
Expand Down Expand Up @@ -455,23 +466,23 @@ jobs:

- name: Upload Qwik Distribution Artifact
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
uses: actions/upload-artifact@master
uses: actions/upload-artifact@v3
with:
name: builderio-qwik-distribution
path: packages/qwik/dist/*
if-no-files-found: error

- name: Build QwikCity / QwikLabs
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
run: pnpm tsm scripts/index.ts --tsc --qwikcity --qwiklabs --api
run: pnpm tsm scripts/index.ts --tsc --qwikcity --qwiklabs --api --eslint

- name: Print QwikCity Lib Build
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
run: tree packages/qwik-city/lib/

- name: Upload QwikCity Build Artifacts
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
uses: actions/upload-artifact@master
uses: actions/upload-artifact@v3
with:
name: builderio-qwikcity-distribution
path: packages/qwik-city/lib/
Expand All @@ -483,7 +494,7 @@ jobs:

- name: Upload QwikLabs Build Artifacts
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
uses: actions/upload-artifact@master
uses: actions/upload-artifact@v3
with:
name: builderio-qwiklabs-distribution
path: |
Expand Down Expand Up @@ -543,7 +554,10 @@ jobs:
mv builderio-qwiklabs-distribution/vite/* packages/qwik-labs/vite/
- name: Install NPM Dependencies
run: pnpm install --frozen-lockfile
run: |
# Ensure that the qwik binary gets made
mkdir -p packages/qwik/dist/bindings/
pnpm install --frozen-lockfile
- name: Commit Build Artifacts
if: ${{ needs.changes.outputs.fullbuild == 'true' && github.event_name == 'push' }}
Expand Down Expand Up @@ -622,15 +636,18 @@ jobs:
- name: Install NPM Dependencies
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
run: pnpm install --frozen-lockfile
run: |
# Ensure that the qwik binary gets made
mkdir -p packages/qwik/dist/bindings/
pnpm install --frozen-lockfile
- name: Install Playwright
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
run: npx playwright install ${{ matrix.settings.browser }} --with-deps

- name: Playwright E2E Tests
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
run: pnpm run test.e2e.${{ matrix.settings.browser }}
run: pnpm run test.e2e.${{ matrix.settings.browser }} --timeout 60000 --retries 3 --workers 1

- name: Validate Create Qwik Cli
if: ${{ needs.changes.outputs.fullbuild == 'true' }}
Expand Down Expand Up @@ -659,7 +676,13 @@ jobs:
- run: corepack enable

- name: Install NPM Dependencies
run: pnpm install --frozen-lockfile
run: |
# Ensure that the qwik binary gets made
mkdir -p packages/qwik/dist/bindings/
pnpm install --frozen-lockfile
- name: Build core
run: pnpm run build.core

- name: Unit Tests
run: pnpm run test.unit
Expand Down Expand Up @@ -749,12 +772,19 @@ jobs:
- run: corepack enable

- name: Install NPM Dependencies
run: pnpm install --frozen-lockfile
run: |
# Ensure that the qwik binary gets made
mkdir -p packages/qwik/dist/bindings/
pnpm install --frozen-lockfile
- name: Prettier Check
if: ${{ always() }}
run: pnpm run lint.prettier

- name: Build ESLint
if: ${{ always() }}
run: pnpm tsm scripts/index.ts --eslint

- name: ESLint Check
if: ${{ always() }}
run: pnpm run lint.eslint
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
etc
temp
.history
.lh
*.
**/*.log
*.node
Expand All @@ -16,6 +17,7 @@ qwik-app/
/server/
/starters/**/server/
/packages/*/server/
!/packages/qwik/server/
/packages/*/src/styled-system/
todo-express/
target
Expand All @@ -37,6 +39,7 @@ tsdoc-metadata.json
.idea
.eslintcache
test-results
.direnv

# Package Managers
.yarn/*
Expand All @@ -45,3 +48,4 @@ test-results

# Local Netlify folder
.netlify
sandbox
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
18.17
20.11
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,13 @@ packages/docs/server
packages/docs/src/routes/api
packages/docs/**/*.md
packages/docs/**/*.mdx
packages/docs/public/repl/bundled
packages/insights/drizzle
packages/insights/.netlify
packages/insights/scripts
packages/insights/**/*.gen.d.ts
packages/qwik-labs/lib-types
packages/qwik-labs/vite

# TODO: Figure out why this doesn't pass in CI
packages/qwik/src/core/props/props.ts
Expand Down
11 changes: 10 additions & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,15 @@
"program": "${workspaceFolder}/packages/docs/node_modules/vite/bin/vite.js",
"args": ["--mode", "ssr", "--force"]
},
{
"type": "node",
"name": "insights dev.debug",
"request": "launch",
"skipFiles": ["<node_internals>/**"],
"cwd": "${workspaceFolder}/packages/insights",
"program": "${workspaceFolder}/packages/insights/node_modules/vite/bin/vite.js",
"args": ["--mode", "ssr", "--force"]
},
{
"type": "node",
"name": "docs build.client",
Expand Down Expand Up @@ -49,7 +58,7 @@
"internalConsoleOptions": "neverOpen",
"program": "${workspaceFolder}/./node_modules/vitest/vitest.mjs",
"cwd": "${workspaceFolder}",
"args": ["--threads=false", "packages/qwik/src/core/container/render.unit.tsx"]
"args": ["${file}"]
}
]
}
Loading

0 comments on commit 6d67d21

Please sign in to comment.