Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

txtgen

Package Overview
Dependencies
Maintainers
1
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

txtgen - npm Package Compare versions

Comparing version 0.1.21 to 0.1.30

8

dist/txtgen.min.js
/**
* txtgen
* v0.1.21
* built: Thu, 16 Jun 2016 09:38:53 GMT
* git: git@github.com:ndaidong/txtgen.git
* author: Dong Nguyen <ndaidong@gmail.com> (https://twitter.com/ndaidong)
* v0.1.30
* built: Fri, 17 Jun 2016 09:26:07 GMT
* git: https://github.com/ndaidong/txtgen
* author: @ndaidong
* License: MIT

@@ -8,0 +8,0 @@ **/

{
"version": "0.1.21",
"version": "0.1.30",
"name": "txtgen",

@@ -8,5 +8,5 @@ "description": "Util for generating random sentences, paragraphs and articles in English",

"type": "git",
"url": "git@github.com:ndaidong/txtgen.git"
"url": "https://github.com/ndaidong/txtgen"
},
"author": "Dong Nguyen <ndaidong@gmail.com> (https://twitter.com/ndaidong)",
"author": "@ndaidong",
"main": "./index.js",

@@ -13,0 +13,0 @@ "engines": {

@@ -15,64 +15,37 @@ # txtgen

[How does it work?](http://ndaidong.github.io/txtgen/).
[See how it works?](http://ndaidong.github.io/txtgen/)
# Setup
## Setup
##### Node.js
- Node.js
```
npm install txtgen --save
```
```
npm install txtgen --save
```
##### SystemJS
- CDN
```
System.config({
baseUrl: '/path/to/js/folder',
map: {
txtgen: 'txtgen.min'
}
});
[txtgen.min.js](https://cdn.rawgit.com/ndaidong/txtgen/master/dist/txtgen.min.js)
System.import('txtgen').then((txtgen) => {
// use txtgen here
});
```
```
<script type="text/javascript" src="https://cdn.rawgit.com/ndaidong/txtgen/master/dist/txtgen.min.js"></script>
```
##### RequireJS
- This library also supports ES6 Module, AMD and UMD style.
```
require.config({
baseUrl: '/path/to/js/folder',
paths: {
txtgen: 'txtgen.min'
}
});
requirejs('txtgen', (txtgen) => {
// use txtgen here
});
```
##### CDN
```
<script type="text/javascript" src="https://cdn.rawgit.com/ndaidong/txtgen/master/dist/txtgen.min.js"></script>
```
# Usage
```
var txtgen = require('txtgen');
var txtgen = require('txtgen');
let sentence = txtgen.sentence();
console.log(sentence);
let sentence = txtgen.sentence();
console.log(sentence);
let paragraph = txtgen.paragraph();
console.log(paragraph);
let paragraph = txtgen.paragraph();
console.log(paragraph);
let article = txtgen.article();
console.log(article);
let article = txtgen.article();
console.log(article);
```

@@ -79,0 +52,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc