Skip to content

Commit

Permalink
Merge pull request #33 from MIERUNE/ci-release
Browse files Browse the repository at this point in the history
CI: release to npm
  • Loading branch information
ciscorn authored Nov 25, 2024
2 parents 740eb96 + dd71aae commit 1e049d1
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 7 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Publish Package to npm

on:
release:
types: [published]

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
cache: "pnpm"
registry-url: 'https://registry.npmjs.org'
- run: pnpm install
- run: pnpm publish --provenance --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "svelte-maplibre-gl",
"version": "0.0.7",
"version": "0.0.8",
"license": "(MIT OR Apache-2.0)",
"description": "Svelte library for using MapLibre GL JS as reactive components",
"scripts": {
Expand Down
12 changes: 6 additions & 6 deletions src/lib/maplibre/map/MapLibre.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -312,32 +312,32 @@
// Accessors
$effect(() => {
if (map && showTileBoundaries !== undefined) {
if (map && showTileBoundaries !== undefined && !firstRun) {
map.showTileBoundaries = showTileBoundaries;
}
});
$effect(() => {
if (map && showPadding !== undefined) {
if (map && showPadding !== undefined && !firstRun) {
map.showPadding = showPadding;
}
});
$effect(() => {
if (map && showCollisionBoxes !== undefined) {
if (map && showCollisionBoxes !== undefined && !firstRun) {
map.showCollisionBoxes = showCollisionBoxes;
}
});
$effect(() => {
if (map && showOverdrawInspector !== undefined) {
if (map && showOverdrawInspector !== undefined && !firstRun) {
map.showOverdrawInspector = showOverdrawInspector;
}
});
$effect(() => {
if (map && repaint !== undefined) {
if (map && repaint !== undefined && !firstRun) {
map.repaint = repaint;
}
});
$effect(() => {
if (map && vertices !== undefined) {
if (map && vertices !== undefined && !firstRun) {
map.vertices = vertices;
}
});
Expand Down

0 comments on commit 1e049d1

Please sign in to comment.