Skip to content

Commit 7684e02

Browse files
author
Alberto
committed
Merge with origin/master
2 parents e571b93 + 7444c6e commit 7684e02

File tree

12 files changed

+73
-14
lines changed

12 files changed

+73
-14
lines changed

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,6 @@
11

22
node_modules/
3+
4+
coverage/
5+
6+
.coveralls.yml

.travis.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
language: node_js
2+
node_js:
3+
- '8'
4+
- '10'
5+
- '12'
6+
sudo: false
7+
after_success: npm run coverage

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# Lit Element Redux
22
Redux connector for lit-element components. Create the store and connect your lit-element components using Redux standards.
33

4-
54
[![npm version](https://img.shields.io/npm/v/lit-element-redux?style=flat-square)](https://www.npmjs.com/package/lit-element-redux)
6-
[![npm downloads](https://img.shields.io/npm/dm/lit-element-redux?style=flat-square)](https://www.npmjs.com/package/lit-element-redux)
5+
[![travis build](https://img.shields.io/travis/com/albertopumar/lit-element-redux?style=flat-square)](https://travis-ci.com/albertopumar/lit-element-redux)
76
[![npm license](https://img.shields.io/npm/l/lit-element-redux?style=flat-square)](https://www.npmjs.com/package/lit-element-redux)
8-
7+
[![coverage status](https://img.shields.io/coveralls/github/albertopumar/lit-element-redux?style=flat-square)](https://coveralls.io/github/albertopumar/lit-element-redux)
8+
[![dependencies status](https://img.shields.io/david/albertopumar/lit-element-redux?style=flat-square)](https://david-dm.org/albertopumar/lit-element-redux)
99

1010
# Overview
1111
Create the store using the connector's function ``createStore`` in order to make Redux ``store`` available for all the connected components:

package-lock.json

Lines changed: 33 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
"description": "Redux connector for lit-element",
55
"main": "index.js",
66
"scripts": {
7-
"test": "jest"
7+
"test": "jest",
8+
"coverage": "jest --coverage --coverageReporters=text-lcov | coveralls"
89
},
910
"author": "Alberto Pumar Jiménez",
1011
"license": "MIT",
@@ -23,6 +24,7 @@
2324
"@babel/core": "^7.8.4",
2425
"@babel/preset-env": "^7.8.4",
2526
"babel-jest": "^25.1.0",
27+
"coveralls": "^3.0.9",
2628
"jest": "^25.1.0"
2729
}
28-
}
30+
}
File renamed without changes.
File renamed without changes.
File renamed without changes.

tests/__mocks__/reducer.js

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
import { INCREMENT, DECREMENT } from './type.js';
2+
3+
function counterReducer(state = 0, action) {
4+
switch (action.type) {
5+
case INCREMENT:
6+
return state + 1;
7+
case DECREMENT:
8+
return state - 1;
9+
default:
10+
return state;
11+
}
12+
}
13+
14+
export default counterReducer;
File renamed without changes.

0 commit comments

Comments
 (0)