Skip to content

Commit

Permalink
Update README examples and make custom factory name explicit
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomas Parisot committed Feb 13, 2017
1 parent 5f8d3f0 commit 13df668
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 8 deletions.
7 changes: 0 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -170,19 +170,12 @@ const tldjs = require('tldjs');
tldjs.getDomain('localhost'); // returns null
tldjs.getSubdomain('vhost.localhost'); // returns null

<<<<<<< HEAD
const myTldjs = tldjs.fromUserSettings({
validHosts: ['localhost']
});

myTldjs.getDomain('localhost'); // returns 'localhost'
myTldjs.getSubdomain('vhost.localhost'); // returns 'vhost'
=======
var customTld = tld.init(['localhost']);

customTld.getDomain('localhost'); // returns 'localhost'
customTld.getSubdomain('vhost.localhost'); // returns 'vhost'
>>>>>>> Add documentation and simplify #init signature
```

## Updating the TLDs List
Expand Down
1 change: 0 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ var tldExists = require('./lib/tld-exists.js');

/**
* Creates a new instance of tldjs
*
* @param {Object.<rules,validHosts>} options [description]
* @return {tldjs|Object} [description]
*/
Expand Down

0 comments on commit 13df668

Please sign in to comment.