-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* initial refactoring * typing * update ts & more tests * fix travis * update README & rm files * nycrc * npm badge
- Loading branch information
1 parent
46a020d
commit 4ee76a2
Showing
22 changed files
with
146 additions
and
3,027 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
.* | ||
!.gitignore | ||
!.travis.yml | ||
!.coveralls.yml | ||
!.babelrc | ||
!.nycrc | ||
**.log | ||
**.lock | ||
**-lock.json | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
"extension": [ | ||
".ts" | ||
], | ||
"require": [ | ||
"ts-node/register" | ||
], | ||
"include": [ | ||
"src/**/*.ts" | ||
], | ||
"exclude": [ | ||
"**/*.d.ts" | ||
], | ||
"reporter": [ | ||
"html", | ||
"text" | ||
], | ||
"all": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,11 @@ | ||
language: node_js | ||
node_js: | ||
- 10 | ||
- 8 | ||
script: yarn test | ||
after_success: yarn coverage | ||
- 10 | ||
script: npm run test | ||
after_success: npm run coverage | ||
install: | ||
- yarn | ||
- npm install | ||
cache: | ||
yarn: true | ||
directories: | ||
- node_modules | ||
- node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
# common-lang | ||
[![Build Status](https://travis-ci.org/HuehueJS/common-lang.svg?branch=master)](https://travis-ci.org/HuehueJS/common-lang) | ||
[![Coverage Status](https://coveralls.io/repos/github/HuehueJS/common-lang/badge.svg?branch=master)](https://coveralls.io/github/HuehueJS/common-lang?branch=master) | ||
[![npm version](https://badge.fury.io/js/%40huehuejs%2Fcommon-lang.svg)](https://npmjs.com/@huehuejs/common-lang) | ||
[![npm version](https://badge.fury.io/js/%40huehuejs%2Fcommon-lang.svg)](https://npmjs.com/@huehuejs/common-lang) | ||
[![Maintainability](https://api.codeclimate.com/v1/badges/24f83743eeb7bff31d66/maintainability)](https://codeclimate.com/github/HuehueJS/common-lang/maintainability) | ||
[![Test Coverage](https://api.codeclimate.com/v1/badges/24f83743eeb7bff31d66/test_coverage)](https://codeclimate.com/github/HuehueJS/common-lang/test_coverage) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,43 @@ | ||
{ | ||
"name": "@huehuejs/common-lang", | ||
"version": "0.0.1", | ||
"private": false, | ||
"version": "0.1.0", | ||
"description": "Exploring", | ||
"main": "index.js", | ||
"types": "index.d.ts", | ||
"files": [ | ||
"**/*.js" | ||
"**/*" | ||
], | ||
"repository": "https://github.com/HuehueJS/common-lang", | ||
"author": "HuehueJs", | ||
"license": "BSD", | ||
"private": false, | ||
"license": "MIT", | ||
"standard": { | ||
"ignore": [ | ||
"coverage/**", | ||
"node_modules/**", | ||
"src/**" | ||
"node_modules/**" | ||
] | ||
}, | ||
"scripts": { | ||
"build": "babel ./src -d ./dist", | ||
"build-dev": "babel ./src -d ./dist --source-maps inline", | ||
"predeploy": "rm -rf dist && mkdir -p dist && npm run build && cp ./package.json ./dist/", | ||
"deploy": "cd ./dist && npm publish --access public", | ||
"postdeploy": "cd ..", | ||
"test": "nyc --reporter=html --reporter=text mocha --recursive --compilers js:babel-core/register", | ||
"coverage": "nyc report --reporter=text-lcov | coveralls" | ||
"prebuild": "rm -rf dist", | ||
"build": "tsc", | ||
"postbuild": "cp package.json dist/", | ||
"test": "nyc --reporter=html --reporter=text mocha test/**/*.spec.ts", | ||
"predeploy": "npm run build", | ||
"deploy": "cd dist/ && npm publish --access public", | ||
"coverage": "nyc report --reporter=text-lcov | codeclimate-test-reporter " | ||
}, | ||
"devDependencies": { | ||
"babel": "^6.23.0", | ||
"babel-cli": "^6.26.0", | ||
"babel-preset-env": "^1.6.1", | ||
"babel-preset-es2018": "^1.0.0", | ||
"@types/chai": "^4.1.4", | ||
"@types/mocha": "^5.2.5", | ||
"chai": "^4.1.2", | ||
"coveralls": "^3.0.1", | ||
"mocha": "^5.1.1", | ||
"nyc": "^11.7.1" | ||
"chai-string": "^1.4.0", | ||
"codeclimate-test-reporter": "^0.5.0", | ||
"mocha": "^5.2.0", | ||
"nyc": "^12.0.2", | ||
"ts-node": "^7.0.0", | ||
"typescript": "^3.1.3" | ||
}, | ||
"directories": { | ||
"test": "test" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { expect } from 'chai'; | ||
import { isString } from '../src/string/index'; | ||
import { noop } from '../src'; | ||
|
||
describe("#noop", () => { | ||
it('noop should do nothing', () => { | ||
const anyValue = 'Tony Stark'; | ||
expect(noop(anyValue)).to.equal(anyValue); | ||
}) | ||
}) |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
{ | ||
"compileOnSave": false, | ||
"compilerOptions": { | ||
"declarationDir": "./dist/", | ||
"outDir": "./dist/", | ||
"allowSyntheticDefaultImports": true, | ||
"sourceMap": true, | ||
"declaration": true, | ||
"moduleResolution": "node", | ||
"emitDecoratorMetadata": true, | ||
"experimentalDecorators": true, | ||
"target": "es5", | ||
"typeRoots": [ | ||
"node_modules/@types" | ||
], | ||
"lib": [ | ||
"es2017", | ||
"es2017.object", | ||
"dom" | ||
], | ||
"plugins": [ | ||
{ | ||
"name": "tslint-language-service" | ||
} | ||
] | ||
}, | ||
"include": [ | ||
"./src" | ||
] | ||
} |
Oops, something went wrong.