Skip to content

Commit 4625aa0

Browse files
committed
Travis publish
1 parent eb60632 commit 4625aa0

File tree

2 files changed

+26
-26
lines changed

2 files changed

+26
-26
lines changed

.travis.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@ install:
1818
script:
1919
- npm run test
2020
- npm run test:coveralls
21-
- npm run prepublish
21+
- npm run publish
2222

2323
deploy:
2424
provider: npm
25-
email: EMAIL_ADDRESS
26-
api_key: AUTH_TOKEN
25+
email: $EMAIL_ADDRESS
26+
api_key: $AUTH_TOKEN
2727
on:
2828
branch: master
2929
skip_cleanup: true

README.md

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
[![npm](https://img.shields.io/npm/v/vue-sweetalert2.svg)](https://www.npmjs.com/package/vue-sweetalert2)
44

5+
[![Coverage Status](https://coveralls.io/repos/github/avil13/vue-sweetalert2/badge.svg?branch=master)](https://coveralls.io/github/avil13/vue-sweetalert2?branch=master)
6+
57
Vue.js wrapper for SweetAlert2. With support SSR.
68

79
![VueSweetalert2](assets/logo.png)
@@ -15,11 +17,11 @@ Vue.js wrapper for SweetAlert2. With support SSR.
1517
## Get started
1618

1719
### Basics
20+
1821
```bash
1922
npm install -S vue-sweetalert2
2023
```
2124

22-
2325
```js
2426
// main.js
2527
import Vue from 'vue';
@@ -40,44 +42,50 @@ Now in the global object, you can access all the methods of [sweetalert2](https:
4042
</template>
4143

4244
<script>
43-
export default {
44-
methods: {
45-
showAlert(){
46-
// Use sweetalert2
47-
this.$swal('Hello Vue world!!!');
48-
}
49-
}
50-
}
45+
export default {
46+
methods: {
47+
showAlert() {
48+
// Use sweetalert2
49+
this.$swal('Hello Vue world!!!');
50+
},
51+
},
52+
};
5153
</script>
5254
```
5355

5456
// Or
57+
5558
```js
5659
Vue.swal('Hello Vue world!!!');
5760
```
5861

5962
### Global options
63+
6064
If you want to add global options like button colors, do something like this:
65+
6166
```js
6267
// main.js
6368
import Vue from 'vue';
6469
import VueSweetalert2 from 'vue-sweetalert2';
6570

6671
const options = {
67-
confirmButtonColor: '#41b882',
68-
cancelButtonColor: '#ff7674'
69-
}
72+
confirmButtonColor: '#41b882',
73+
cancelButtonColor: '#ff7674',
74+
};
7075

71-
Vue.use(VueSweetalert2, options)
76+
Vue.use(VueSweetalert2, options);
7277
```
78+
7379
### Custom styling
80+
7481
Using scss styles are loaded so
82+
7583
```js
7684
// main.js
7785
import Vue from 'vue';
7886
import VueSweetalert2 from 'vue-sweetalert2';
7987

80-
Vue.use(VueSweetalert2)
88+
Vue.use(VueSweetalert2);
8189
```
8290

8391
```scss
@@ -89,10 +97,6 @@ $swal2-background: #990000;
8997
@import '~sweetalert2/src/sweetalert2';
9098
```
9199

92-
93-
94-
95-
96100
## Nuxt.js
97101

98102
Install dependencies:
@@ -105,9 +109,7 @@ Add `vue-sweetalert2/nuxt` to modules section of `nuxt.config.js`
105109

106110
```js
107111
{
108-
modules: [
109-
'vue-sweetalert2/nuxt'
110-
]
112+
modules: ['vue-sweetalert2/nuxt'];
111113
}
112114
```
113115

@@ -126,6 +128,4 @@ Or pass in global options like this:
126128
}
127129
```
128130
129-
130131
## The documentation for `sweetalert2`, you can find [here](https://sweetalert2.github.io/).
131-

0 commit comments

Comments
 (0)