Skip to content

Commit

Permalink
Merge a17af24 into 3a12c69
Browse files Browse the repository at this point in the history
  • Loading branch information
rkrauskopf committed Feb 14, 2019
2 parents 3a12c69 + a17af24 commit dcee1a3
Show file tree
Hide file tree
Showing 32 changed files with 3,275 additions and 8,276 deletions.
2 changes: 1 addition & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ indent_style = space
indent_size = 2

# JavaScript-specific settings
[*.js]
[*.{js,ts}]
quote_type = double
continuation_indent_size = 2
curly_bracket_next_line = false
Expand Down
2 changes: 1 addition & 1 deletion .eslintrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ extends:
- modular/style
- modular/browser
- modular/node
- modular/es5
- modular/es6
25 changes: 25 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Git attributes
# https://git-scm.com/docs/gitattributes
# https://git-scm.com/book/en/v2/Customizing-Git-Git-Attributes

# Normalize line endings for all files that git determines to be text.
# https://git-scm.com/docs/gitattributes#gitattributes-Settostringvalueauto
* text=auto

# Normalize line endings to LF on checkin, and do NOT convert to CRLF when checking-out on Windows.
# https://git-scm.com/docs/gitattributes#gitattributes-Settostringvaluelf
*.txt text eol=lf
*.html text eol=lf
*.md text eol=lf
*.css text eol=lf
*.scss text eol=lf
*.map text eol=lf
*.js text eol=lf
*.jsx text eol=lf
*.ts text eol=lf
*.tsx text eol=lf
*.json text eol=lf
*.yml text eol=lf
*.yaml text eol=lf
*.xml text eol=lf
*.svg text eol=lf
6 changes: 4 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,7 @@ node_modules
# Test output
/.nyc_output
/coverage
/dist/*.coverage.js
/test/dir/**/*symlink*

# Build output
/cjs
/esm
13 changes: 9 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,16 @@ os:
- osx
- windows

script: npm run lint && npm run coverage:node
before_script:
- npm run lint
- npm run build

script:
- npm run coverage:node

after_success:
# concatenate all code-coverage data into a single file
- ls -R1 coverage/*/lcov.info
- ls -Rlh coverage/*/lcov.info
- cat coverage/*/lcov.info > ./coverage/lcov.info

# send code-coverage data to Coveralls
Expand All @@ -45,11 +50,11 @@ jobs:
- name: Browser tests (Windows via SauceLabs)
os: linux
script: npm run coverage:browser
env: WINDOWS=true
env: KARMA_PLATFORM=win32

- stage: Deploy
name: Publish to npm
script: npm run build
script: true
after_success: true
deploy:
provider: npm
Expand Down
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Static mock data
------------------------------
==============================
Static mock data (as opposed to randomly-generated mock data) for sample apps, demos, and POCs.

[![Build Status](https://api.travis-ci.com/JS-DevTools/static-mock-data.svg?branch=master)](https://travis-ci.com/JS-DevTools/static-mock-data)
Expand All @@ -14,8 +14,8 @@ Static mock data (as opposed to randomly-generated mock data) for sample apps, d

Features
--------------------------
* __[100 mock employees](https://raw.githubusercontent.com/James-Mesinger/static-mock-data/master/employees.json)__, with names, addresses, phone numbers, etc.
* __[100 mock projects](https://raw.githubusercontent.com/James-Mesinger/static-mock-data/master/projects.json)__, with names, dates, departments, employees assigned, etc.
* __[100 mock employees](https://raw.githubusercontent.com/JS-DevTools/static-mock-data/master/employees.json)__, with names, addresses, phone numbers, etc.
* __[100 mock projects](https://raw.githubusercontent.com/JS-DevTools/static-mock-data/master/projects.json)__, with names, dates, departments, employees assigned, etc.
* __[Full-size](https://github.com/JS-DevTools/static-mock-data/blob/master/portraits/jdoe.jpg)__ and __[thumbnail](https://github.com/JS-DevTools/static-mock-data/blob/master/portraits/jdoe-thumb.jpg)__ photos for each employee
* No dependencies
* [Tested](https://jsdevtools.org/static-mock-data/test/) in Node.js and all modern web browsers on Mac, Windows, and Linux
Expand All @@ -40,7 +40,7 @@ The mock data can be used as plain JSON or as JavaScript arrays of objects.
##### Raw JSON
```javascript
var employeeJSON = require('static-mock-data/employees.json');
employeeJSON.forEach(function(employee) {
employeeJSON.forEach((employee) => {
console.log(employee.dob); // string (in ISO 8601 zulu format)
console.log(employee.portrait); // relative file path
});
Expand All @@ -49,7 +49,7 @@ employeeJSON.forEach(function(employee) {
##### JavaScript Objects
```javascript
var mockData = require('static-mock-data');
mockData.employees.forEach(function(employee) {
mockData.employees.forEach((employee) => {
console.log(employee.dob); // Date object
console.log(employee.portrait); // absolute file path
});
Expand All @@ -62,7 +62,7 @@ Reference [`static-mock-data.js`](dist/static-mock-data.js) or [`static-mock-dat
```html
<script src="https://cdn.rawgit.com/JS-DevTools/static-mock-data/master/dist/static-mock-data.js"></script>
<script>
mock.data.employees.forEach(function(employee) {
mock.data.employees.forEach((employee) => {
console.log(employee.dob); // Date object
});
</script>
Expand Down
26 changes: 0 additions & 26 deletions appveyor.yml

This file was deleted.

6 changes: 0 additions & 6 deletions banner.txt

This file was deleted.

0 comments on commit dcee1a3

Please sign in to comment.