Skip to content
Merged
27 changes: 22 additions & 5 deletions .github/workflows/deploy-confetti.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,29 +21,45 @@ jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
with:
fetch-depth: 0

- uses: pnpm/action-setup@v5
with:
version: 10
- name: Check for confetti changes
id: changes
run: |
if [ "${{ github.event_name }}" = "push" ]; then
if git diff --name-only "${{ github.event.before }}" "${{ github.sha }}" | grep -q "^websites/confetti/"; then
echo "changed=true" >> "$GITHUB_OUTPUT"
else
echo "changed=false" >> "$GITHUB_OUTPUT"
fi
else
echo "changed=true" >> "$GITHUB_OUTPUT"
fi

- uses: pnpm/action-setup@v6
if: steps.changes.outputs.changed == 'true'

- uses: actions/setup-node@v4
- uses: actions/setup-node@v6
if: steps.changes.outputs.changed == 'true'
with:
node-version: '24'
cache: 'pnpm'
cache-dependency-path: websites/confetti/pnpm-lock.yaml

- name: Install dependencies
if: steps.changes.outputs.changed == 'true'
working-directory: websites/confetti
run: pnpm install

- name: Build
if: steps.changes.outputs.changed == 'true'
working-directory: websites/confetti
run: pnpm run build:ci

- name: Generate GitHub App token
if: steps.changes.outputs.changed == 'true'
id: app-token
uses: actions/create-github-app-token@v1
with:
Expand All @@ -54,6 +70,7 @@ jobs:
confetti

- name: Deploy to tsparticles/confetti main
if: steps.changes.outputs.changed == 'true'
uses: peaceiris/actions-gh-pages@v4
with:
token: ${{ steps.app-token.outputs.token }}
Expand Down
30 changes: 24 additions & 6 deletions .github/workflows/deploy-website.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,33 +21,50 @@ jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
with:
fetch-depth: 0

- uses: pnpm/action-setup@v5
with:
version: 10
- name: Check for website changes
id: changes
run: |
if [ "${{ github.event_name }}" = "push" ]; then
if git diff --name-only "${{ github.event.before }}" "${{ github.sha }}" | grep -q "^websites/website/"; then
echo "changed=true" >> "$GITHUB_OUTPUT"
else
echo "changed=false" >> "$GITHUB_OUTPUT"
fi
else
echo "changed=true" >> "$GITHUB_OUTPUT"
fi

- uses: pnpm/action-setup@v6
if: steps.changes.outputs.changed == 'true'

- uses: actions/setup-node@v4
- uses: actions/setup-node@v6
if: steps.changes.outputs.changed == 'true'
with:
node-version: '22'
node-version: '24'
cache: 'pnpm'
cache-dependency-path: websites/website/pnpm-lock.yaml

- name: Install dependencies
if: steps.changes.outputs.changed == 'true'
working-directory: websites/website
run: pnpm install --frozen-lockfile

- name: Lint
if: steps.changes.outputs.changed == 'true'
working-directory: websites/website
run: pnpm run lint

- name: Build
if: steps.changes.outputs.changed == 'true'
working-directory: websites/website
run: pnpm run docs:build

- name: Generate GitHub App token
if: steps.changes.outputs.changed == 'true'
id: app-token
uses: actions/create-github-app-token@v1
with:
Expand All @@ -58,6 +75,7 @@ jobs:
website

- name: Deploy to tsparticles/website main
if: steps.changes.outputs.changed == 'true'
uses: peaceiris/actions-gh-pages@v4
with:
token: ${{ steps.app-token.outputs.token }}
Expand Down
25 changes: 3 additions & 22 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,31 +19,12 @@ jobs:
name: Checkout [main]
with:
fetch-depth: 0
- uses: pnpm/action-setup@v6

- uses: actions/setup-node@v6
with:
node-version: '24'
- uses: pnpm/action-setup@v6.0.0
name: Install pnpm
id: pnpm-install
with:
version: 10
run_install: false
- name: Get pnpm version
id: pnpm-version
run: |
echo "$(pnpm --version)"
cache: 'pnpm'

- name: Get pnpm store directory
id: pnpm-cache
run: |
echo "::set-output name=pnpm_cache_dir::$(pnpm store path)"

- uses: actions/cache@v5
name: Setup pnpm cache
with:
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- run: pnpm install --no-frozen-lockfile
- run: pnpm run build:ci:json
20 changes: 3 additions & 17 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,26 +28,12 @@ jobs:
- name: Derive SHAs for nx affected
uses: nrwl/nx-set-shas@v5

- uses: pnpm/action-setup@v6

- uses: actions/setup-node@v6
with:
node-version: "24"

- uses: pnpm/action-setup@v5.0.0
with:
cache: true

- name: Get pnpm store directory
id: pnpm-cache
run: |
echo "pnpm_cache_dir=$(pnpm store path)" >> $GITHUB_OUTPUT

- uses: actions/cache@v5
name: Setup pnpm cache
with:
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
cache: 'pnpm'

- name: Install dependencies
run: pnpm install
Expand Down
20 changes: 3 additions & 17 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,28 +30,14 @@ jobs:
with:
fetch-depth: 0

- uses: pnpm/action-setup@v6

- uses: actions/setup-node@v6
name: Setup Node.js
with:
node-version: "24"
registry-url: https://registry.npmjs.org

- uses: pnpm/action-setup@v5.0.0
name: Install pnpm
with:
cache: true

- name: Get pnpm store directory
id: pnpm-cache
run: echo "pnpm_cache_dir=$(pnpm store path)" >> $GITHUB_OUTPUT

- uses: actions/cache@v5
name: Setup pnpm cache
with:
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
cache: 'pnpm'

- name: Install Dependencies
run: pnpm install
Expand Down
5 changes: 5 additions & 0 deletions demo/angular/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
{
"name": "@tsparticles/angular-demo",
"version": "4.0.0-beta.15",
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/angular"
},
"scripts": {
"ng": "ng",
"start": "ng serve -o",
Expand Down
5 changes: 5 additions & 0 deletions demo/astro/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
"type": "module",
"version": "4.0.0-beta.15",
"private": true,
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/astro"
},
"scripts": {
"dev": "astro dev",
"start": "astro dev",
Expand Down
5 changes: 5 additions & 0 deletions demo/electron/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
"description": "",
"main": "app/index.cjs",
"private": true,
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/electron"
},
"scripts": {
"start": "pnpm run build:client && electron .",
"build": "pnpm run build:client && pnpx @electron/packager . electron-demo",
Expand Down
5 changes: 5 additions & 0 deletions demo/ember/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
"version": "4.0.0-beta.15",
"private": true,
"description": "Ember demo for @tsparticles/ember",
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/ember"
},
"engines": {
"node": "14.* || 16.* || >= 18"
},
Expand Down
5 changes: 5 additions & 0 deletions demo/inferno/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
"private": true,
"description": "> TODO: description",
"main": "index.js",
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/inferno"
},
"scripts": {
"build": "webpack --mode production",
"build:ci": "webpack --mode production",
Expand Down
5 changes: 5 additions & 0 deletions demo/ionic/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
"version": "4.0.0-beta.15",
"author": "Matteo Bruni <matteo.bruni@me.com>",
"homepage": "https://particles.js.org",
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/ionic"
},
"scripts": {
"ng": "ng",
"start": "ng serve",
Expand Down
3 changes: 2 additions & 1 deletion demo/jquery/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
"license": "MIT",
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git"
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/jquery"
},
"scripts": {
"build": "pnpm run build:style && pnpm run build:index",
Expand Down
5 changes: 5 additions & 0 deletions demo/lit/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
"private": true,
"description": "A simple web component",
"type": "module",
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/lit"
},
"scripts": {
"build": "tsc",
"build:watch": "tsc --watch",
Expand Down
5 changes: 5 additions & 0 deletions demo/nextjs-legacy/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
"name": "@tsparticles/nextjs-legacy-demo",
"version": "4.0.0-beta.15",
"private": true,
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/nextjs-legacy"
},
"scripts": {
"dev": "next dev",
"build": "next build",
Expand Down
5 changes: 5 additions & 0 deletions demo/nextjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
"name": "@tsparticles/nextjs-demo",
"version": "4.0.0-beta.15",
"private": true,
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/nextjs"
},
"scripts": {
"dev": "next dev",
"build": "next build",
Expand Down
5 changes: 5 additions & 0 deletions demo/nuxt2/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
"name": "@tsparticles/nuxt2-demo",
"version": "4.0.0-beta.15",
"private": true,
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/nuxt2"
},
"scripts": {
"dev": "nuxt",
"build": "nuxt build",
Expand Down
5 changes: 5 additions & 0 deletions demo/nuxt3/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
"version": "4.0.0-beta.15",
"private": true,
"type": "module",
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/nuxt3"
},
"scripts": {
"build": "nuxt build",
"dev": "nuxt dev",
Expand Down
5 changes: 5 additions & 0 deletions demo/nuxt4/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
"version": "4.0.0-beta.15",
"private": true,
"type": "module",
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/nuxt4"
},
"scripts": {
"build": "nuxt build",
"dev": "nuxt dev",
Expand Down
3 changes: 2 additions & 1 deletion demo/preact/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"license": "MIT",
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git"
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/preact"
},
"eslintConfig": {
"extends": "preact",
Expand Down
5 changes: 5 additions & 0 deletions demo/qwik/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
"version": "4.0.0-beta.15",
"private": true,
"type": "module",
"repository": {
"type": "git",
"url": "git+https://github.com/tsparticles/tsparticles.git",
"directory": "demo/qwik"
},
"scripts": {
"dev": "vite --mode ssr",
"start": "vite --open --mode ssr",
Expand Down
Loading
Loading