Skip to content

Commit

Permalink
Update plugin, update building logic, implement tests, implement stor…
Browse files Browse the repository at this point in the history
…ybook, implement types, configure github workflow
  • Loading branch information
arthurvasconcelos committed Aug 23, 2019
1 parent 806faf5 commit 98ef214
Show file tree
Hide file tree
Showing 45 changed files with 16,459 additions and 10,269 deletions.
28 changes: 4 additions & 24 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -1,25 +1,5 @@
{
"comments": false,
"env": {
"main": {
"presets": [
[
"env",
{
"modules": false,
"targets": {
"browsers": ["> 1%", "last 2 versions", "not ie <= 8"],
"node": 7
},
"useBuiltIns": true
}
],
"stage-3"
],
"plugins": [
"transform-runtime"
]
}
}
}

"presets": ["@babel/preset-env"],
"plugins": ["@babel/plugin-transform-runtime", "@babel/plugin-proposal-class-properties"],
"comments": false
}
56 changes: 56 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: CI

on: [push, pull_request]

jobs:
Linux:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [10.x, 12.x]
steps:
- uses: actions/checkout@v1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install Dependencies
run: npm install
- name: Build
run: npm run build
- name: Test
run: npm run test
Windows:
runs-on: windows-latest
strategy:
matrix:
node-version: [10.x, 12.x]
steps:
- uses: actions/checkout@v1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install Dependencies
run: npm install
- name: Build
run: npm run build
- name: Test
run: npm run test
MacOS:
runs-on: macOS-latest
strategy:
matrix:
node-version: [10.x, 12.x]
steps:
- uses: actions/checkout@v1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install Dependencies
run: npm install
- name: Build
run: npm run build
- name: Test
run: npm run test
16 changes: 15 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
# Modules
node_modules

# Logs
npm-debug.log

# Tests
cypress/screenshots
cypress/videos

# Editors / IDEs
.idea/*
*.lock
.vscode

# Others
*.lock
*.bak
4 changes: 4 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"printWidth": 100,
"singleQuote": true
}
1 change: 1 addition & 0 deletions .storybook/addons.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
import '@storybook/addon-notes/register-panel';
13 changes: 13 additions & 0 deletions .storybook/config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import { addParameters, configure } from '@storybook/vue';

addParameters({
options: {
panelPosition: 'right',
}
});

function loadStories() {
require('./stories.js');
}

configure(loadStories, module);
27 changes: 27 additions & 0 deletions .storybook/stories.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
import Vue from 'vue';
import { storiesOf } from '@storybook/vue';
import VueIzitoast from '../src/vue-izitoast';
import App from '../examples/App.vue';
import notes from '../examples/README.md';

Vue.use(VueIzitoast);
Vue.component('App', App);

const withSettings = component => ({
...component
});

const stories = storiesOf('VuePlugin', module);

stories
.add(
'Options',
() => withSettings({
template: `
<div>
<App />
</div>
`
}),
{ notes }
);
64 changes: 0 additions & 64 deletions build/build.js

This file was deleted.

54 changes: 0 additions & 54 deletions build/check-versions.js

This file was deleted.

38 changes: 0 additions & 38 deletions build/webpack.base.conf.js

This file was deleted.

70 changes: 0 additions & 70 deletions build/webpack.prod.conf.js

This file was deleted.

1 change: 1 addition & 0 deletions cypress.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
Empty file added cypress/fixtures/.gitkeep
Empty file.
Loading

0 comments on commit 98ef214

Please sign in to comment.