From 5761f7b8033d3d03c9505c161242d9a38787cf36 Mon Sep 17 00:00:00 2001 From: anubra266 Date: Mon, 23 Dec 2024 21:41:15 -0800 Subject: [PATCH] chore: setup --- .github/composite-actions/install.yml | 20 +++++++++ .github/workflows/static.yml | 59 +++++++++++++++++++++++++++ README.md | 54 +++++++++++++++++++++++- 3 files changed, 131 insertions(+), 2 deletions(-) create mode 100644 .github/composite-actions/install.yml create mode 100644 .github/workflows/static.yml diff --git a/.github/composite-actions/install.yml b/.github/composite-actions/install.yml new file mode 100644 index 0000000..5340e50 --- /dev/null +++ b/.github/composite-actions/install.yml @@ -0,0 +1,20 @@ +name: "Install" +description: "Sets up Node.js and runs install" + +runs: + using: composite + steps: + - uses: pnpm/action-setup@v2.4.0 + with: + version: 7 + + - name: Setup Node.js + uses: actions/setup-node@v3 + with: + node-version: 16.x + registry-url: "https://registry.npmjs.org" + cache: "pnpm" + + - name: Install dependencies + shell: bash + run: pnpm install diff --git a/.github/workflows/static.yml b/.github/workflows/static.yml new file mode 100644 index 0000000..447186c --- /dev/null +++ b/.github/workflows/static.yml @@ -0,0 +1,59 @@ +# Simple workflow for deploying static content to GitHub Pages +name: Deploy Demo page + +on: + # Runs on pushes targeting the default branch + push: + branches: ["main"] + + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages +permissions: + contents: read + pages: write + id-token: write + +# Allow one concurrent deployment +concurrency: + group: "pages" + cancel-in-progress: true + +env: + BUILD_PATH: "site" + +jobs: + build: + name: Build + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Install + uses: ./.github/composite-actions/install + - name: Setup Node + uses: actions/setup-node@v3 + - name: Setup Pages + id: pages + uses: actions/configure-pages@v2 + - name: Build with Vite + run: | + pnpm --filter site build + working-directory: ${{ env.BUILD_PATH }} + - name: Upload artifact + uses: actions/upload-pages-artifact@v1 + with: + path: ${{ env.BUILD_PATH }}/site-build + + deploy: + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + needs: build + runs-on: ubuntu-latest + name: Deploy + steps: + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v1 \ No newline at end of file diff --git a/README.md b/README.md index 134601f..8d84488 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,52 @@ -# zag-scrollspy -Simple Agnostic Scrollspy +
+ +

+
+ 📜 +
+ zag-scrollspy +
+
+

+ +
+
+ + npm package + + + npm  downloads + + + NPM + + +GitHub Repo stars + + +
+ Simple Agnostic Scrollspy. + +
+
+
+
+
+
npm i zag-scrollspy
+
+
+
+
+
+
+ +## Install + +```bash +npm i --save zag-scrollspy +#or +yarn add zag-scrollspy +#or +pnpm add zag-scrollspy +``` +