table-layout
Advanced tools
Comparing version 2.0.3 to 2.1.0
{ | ||
"name": "table-layout", | ||
"author": "Lloyd Brookes <75pound@gmail.com>", | ||
"version": "2.0.3", | ||
"version": "2.1.0", | ||
"description": "Stylable text tables, handling ansi colour. Useful for console output.", | ||
@@ -22,5 +22,6 @@ "repository": "https://github.com/75lb/table-layout.git", | ||
"scripts": { | ||
"test": "test-runner test/*.mjs", | ||
"test": "npm run dist && test-runner test/*.mjs", | ||
"docs": "jsdoc2md -c jsdoc.conf -t README.hbs index.mjs -p list --member-index-format list > README.md; echo", | ||
"cover": "nyc npm test && nyc report --reporter=text-lcov | coveralls" | ||
"cover": "nyc npm test && nyc report --reporter=text-lcov | coveralls", | ||
"dist": "rollup -c" | ||
}, | ||
@@ -30,3 +31,3 @@ "dependencies": { | ||
"typical": "^6.0.1", | ||
"wordwrapjs": "^4.0.1" | ||
"wordwrapjs": "^5.0.1" | ||
}, | ||
@@ -37,2 +38,4 @@ "devDependencies": { | ||
"nyc": "^15.1.0", | ||
"rollup": "^2.42.3", | ||
"rollup-plugin-node-resolve": "^5.2.0", | ||
"test-runner": "^0.8.14" | ||
@@ -42,4 +45,5 @@ }, | ||
"index.mjs", | ||
"lib/*.mjs" | ||
"lib/*.mjs", | ||
"dist" | ||
] | ||
} |
@@ -75,2 +75,30 @@ [![view on npm](https://badgen.net/npm/v/table-layout)](https://www.npmjs.org/package/table-layout) | ||
## Load anywhere | ||
This library is compatible with Node.js, the Web and any style of module loader. It can be loaded anywhere, natively without transpilation. | ||
Node.js: | ||
```js | ||
const TableLayout = require('table-layout') | ||
``` | ||
Within Node.js with ECMAScript Module support enabled: | ||
```js | ||
import TableLayout from 'table-layout' | ||
``` | ||
Within an modern browser ECMAScript Module: | ||
```js | ||
import TableLayout from './node_modules/table-layout/dist/index.mjs' | ||
``` | ||
Old browser (adds `window.TableLayout`): | ||
```html | ||
<script nomodule src="./node_modules/table-layout/dist/index.js"></script> | ||
``` | ||
## API Reference | ||
@@ -77,0 +105,0 @@ |
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
80139
13
2224
184
6
1
+ Addedwordwrapjs@5.1.0(transitive)
- Removedreduce-flatten@2.0.0(transitive)
- Removedtypical@5.2.0(transitive)
- Removedwordwrapjs@4.0.1(transitive)
Updatedwordwrapjs@^5.0.1