Skip to content

Commit

Permalink
Fixed Build, Improved Build Process (#54)
Browse files Browse the repository at this point in the history
* removed private addition to package

* Fixed build

* added no frozen lockfile

* changed to correct package name
  • Loading branch information
Harry-Ross authored Jan 2, 2024
1 parent 2b274c5 commit f026a62
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/lint-code.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,5 @@ jobs:
with:
node-version-file: ".nvmrc"
cache: "pnpm"
- run: pnpm i
- run: pnpm install --no-frozen-lockfile
- run: pnpm lint
8 changes: 2 additions & 6 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Publish npm Package

on:
workflow_dispatch:
release:
types: [published]

Expand All @@ -20,17 +21,12 @@ jobs:
cache: "pnpm"

- name: 📦️ Install dependencies
run: pnpm install
run: pnpm install --no-frozen-lockfile

- name: 🏗️ Build
run: |
pnpm build
- name: 📋 Copy package.json + README to dist
run: |
cp package.json dist/
cp README.md dist/
- name: 🚀️ Publish to NPM
run: pnpm publish --no-git-checks --access public
env:
Expand Down
13 changes: 8 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,14 @@
{
"name": "ssw-megamenu",
"private": true,
"name": "ssw.megamenu",
"version": "4.0.0",
"type": "module",
"main": "dist/index.js",
"module": "dist/index.es.js",
"types": "dist/index.d.ts",
"files": [
"dist",
"README.md"
],
"scripts": {
"dev": "vite",
"build": "tsc && vite build",
Expand Down Expand Up @@ -73,8 +79,5 @@
"last 1 safari version"
]
},
"publishConfig": {
"directory": "dist"
},
"packageManager": "[email protected]+sha256.fbcf256db6d06bc189e31df34b3ed61220f3ba9f78a2ca8fe7be0fce4670dbd3"
}

0 comments on commit f026a62

Please sign in to comment.