Skip to content

Commit 9565948

Browse files
authored
Merge pull request #2 from node-projects/feature/slidershow
Create first Version of slidershow #1 --> created project and first v…
2 parents 3acb3f1 + 824da41 commit 9565948

17 files changed

+7188
-0
lines changed

.github/workflows/main.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: Build
2+
on: push
3+
jobs:
4+
build:
5+
runs-on: ubuntu-latest
6+
steps:
7+
- name: Checkout
8+
uses: actions/checkout@v2
9+
- name: Setup Node
10+
uses: actions/setup-node@v2
11+
with:
12+
node-version: '21.x'
13+
registry-url: 'https://registry.npmjs.org'
14+
- name: Install dependencies and build 🔧
15+
run: npm ci && npm run build

.github/workflows/publish.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Publish to NPM
2+
on:
3+
release:
4+
types: [created]
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- name: Checkout
10+
uses: actions/checkout@v2
11+
- name: Setup Node
12+
uses: actions/setup-node@v2
13+
with:
14+
node-version: '21.x'
15+
registry-url: 'https://registry.npmjs.org'
16+
- name: Install dependencies and build 🔧
17+
run: npm ci && npm run build
18+
- name: Publish package on NPM 📦
19+
run: npm publish --access=public
20+
env:
21+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
dist/
2+
node_modules/

.npmignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
src/
2+
sample/
3+
node_modules/
4+
tsconfig.json
5+
.github/

.release-it.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"git": {
3+
"commitMessage": "chore: release v${version}"
4+
},
5+
"github": {
6+
"release": true
7+
},
8+
"npm": {
9+
"publish": false
10+
}
11+
}

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,13 @@
11
# automatic-slidershow-webcomponent
22

3+
# description
4+
a simple slider show as webcomponent..
5+
6+
# development
7+
## upload new version
8+
simple run
9+
10+
npm run release
11+
12+
then you need to go to github and create a release from the uploaded tag.
13+
this will then create a npm package via github action.

custom-elements.json

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
{
2+
"schemaVersion": "1.0.0",
3+
"readme": "README.md",
4+
"modules": [
5+
{
6+
"kind": "javascript-module",
7+
"path": "dist/slider/AutomaticSliderShowWebcomponent.js",
8+
"declarations": [
9+
{
10+
"kind": "class",
11+
"description": "A web component for an automatic slider show",
12+
"name": "AutomaticSliderShowWebcomponent",
13+
"members": [
14+
{
15+
"kind": "property",
16+
"name": "_slideIndex",
17+
"type": {
18+
"text": "number"
19+
}
20+
},
21+
{
22+
"kind": "property",
23+
"name": "_interval",
24+
"type": {
25+
"text": "number"
26+
}
27+
}
28+
],
29+
"superclass": {
30+
"name": "BaseCustomWebComponentConstructorAppend"
31+
},
32+
"tagName": "node-projects-slidershow",
33+
"customElement": true
34+
}
35+
],
36+
"exports": [
37+
{
38+
"kind": "custom-element-definition",
39+
"name": "node-projects-slidershow",
40+
"declaration": {
41+
"name": "AutomaticSliderShowWebcomponent",
42+
"module": "dist/slider/AutomaticSliderShowWebcomponent.js"
43+
}
44+
}
45+
]
46+
}
47+
]
48+
}

0 commit comments

Comments
 (0)