Skip to content
This repository has been archived by the owner on Dec 21, 2020. It is now read-only.

Commit

Permalink
feat(Typescript 2.1.4): Update to TypeScript 2.1.4
Browse files Browse the repository at this point in the history
This might very well be the first functional release.
  • Loading branch information
wmathes committed Jan 11, 2017
1 parent 1776ee1 commit c2e31dd
Show file tree
Hide file tree
Showing 19 changed files with 400 additions and 459 deletions.
13 changes: 13 additions & 0 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"presets": [
"es2015",
"babili"
],
"plugins": [
"remove-comments",
"transform-remove-console",
"transform-remove-debugger",
"minify-simplify"
]
}

6 changes: 0 additions & 6 deletions .gitattributes

This file was deleted.

26 changes: 16 additions & 10 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,12 +1,18 @@
/.idea/
/build/
/coverage/
/dist/
/jspm_packages/
/node_modules/
/report/
/typings/
# tools
.vscode/
.idea/

# builds
lib/
lib.es2015/
umd/*.js
coverage/

# dependencies
node_modules/

# misc
.DS_Store
.tgz
.npmrc
*.tgz
npm-debug.log*
yarn.lock
27 changes: 27 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# tools
.vscode/
.idea/

# tests
lib/**/*.spec.*
lib.es2015/**/*.spec.*
coverage/

# misc
.DS_Store
*.tgz
npm-debug.log*
yarn.lock

# sources and build tools
src/
.npmignore
.babelrc
.editorconfig
.travis.yml
gulpfile.js
karma.conf.js
tsconfig.json
tsconfig.es2015.json
tslint.json
webpack.config.js
26 changes: 8 additions & 18 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,32 +1,22 @@
sudo: required
dist: trusty
language: node_js
node_js: "6"
env:
- NODE_ENV=ci
node_js:
- "6"

cache:
directories:
- node_modules
- jspm_packages
- /usr/local/lib/node_modules
addons:
firefox: "50.0"

before_install:
- export CHROME_BIN=chromium-browser
- export DISPLAY=:99.0
- sh -e /etc/init.d/xvfb start
- npm i -g gulp typings jspm yarn

install:
- yarn
- jspm install
- typings install

script:
- npm run compile -s
- npm run build -s
- npm run test -s
- npm run lint -s
- npm run build -s

#after_success:
# - npm run semantic-release
after_success:
- bash <(curl -s https://codecov.io/bash)
- npm run semantic-release
41 changes: 11 additions & 30 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# ts-module-boilerplate

[![Build Status](https://travis-ci.org/crazyfactory/ts-module-boilerplate.svg)](https://travis-ci.org/crazyfactory/ts-module-boilerplate)
[![Build Status](https://travis-ci.org/crazyfactory/ts-module-boilerplate.svg)](https://travis-ci.com/crazyfactory/ts-module-boilerplate)

This boilerplate allows the quick creation of npm modules written in Typescript.

Expand All @@ -11,70 +11,51 @@ This boilerplate allows the quick creation of npm modules written in Typescript.
- uses karma for testing
- uses travis and semantic-release for deployment
- uses linting, coverage and git hooks to increase code quality.
- is configured to support wallaby

Initially you should:

- clone this repository
- update `package.json` (name, repository and description)
- update `README.md`
- run `npm run setup` once
- uncomment `after_success` block in `.travis.yml` to activate semantic-release

Afterwards you can start implementing classes and tests :)


# My Module name

[![Build Status](https://travis-ci.org/crazyfactory/ts-http-client.svg)](https://travis-ci.org/crazyfactory/ts-module-boilerplate)
[![Build Status](https://travis-ci.org/crazyfactory/ts-module-boilerplate.svg)](https://travis-ci.org/crazyfactory/my-module)
[![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)

My module description

## Requirements

This project requires [nodejs](https://nodejs.org/en/download/) to be installed on your system.

## Quick setup

For a complete installation use `npm run setup`. This will run the steps defined in *Setup* in sequence.
This project requires [nodejs](https://nodejs.org/en/download/) to be installed on your system.

## Setup

For a step by step setup do the following:

1) Install globally required npm packages
- `npm install -g gulp typings jspm yarn`

2) Install project dependencies
- `yarn` (installs npm dependencies; mostly for development; replaces `npm install`)
- `jspm install` (installs the typescript transpiler for jspm to be used during bundling)
- `typings install` (installs typings for jasmine)

## Building

- `npm run build` to compile all sources.

Compiled sources will be saved into `/build` and `/dist`.

## Testing

Build your sources, then use
Install project dependencies
- `npm install`

- `npm run test` to run all tests using karma.
## Tests

Test coverage will be `/coverage`.
- `npm run test` will run karma and test your code. Will also create a code coverage report at `/coverage`.
- Optional: Use WallabyJS for continous testing.

## Code styles

This project uses tslint to enforce similar code styles across source and test files. Passing tslint validation is a CI requirement. You can run and validate your code style locally.

- `npm run lint` lints all typescript files in the project.
- `npm run lint-fix` to also fix most common errors automatically.

## Build and deploy

This package is automatically build and deployed using TravisCI and semantic-release. You can however test the process locally:

- `npm run build` creates a minified ES5 bundle in the `/dist`-folder.
- `npm run build` compile sources into all desired formats.
- `npm run pack` to create the final package.

Note: You'll have to edit package.json to include a version number of your choice. Don't check this in though as the version number is determined by semantic-release.
84 changes: 0 additions & 84 deletions config.js

This file was deleted.

Loading

0 comments on commit c2e31dd

Please sign in to comment.