firebasepath

1.0.3 • Public • Published

Features

  • No dependency!
  • Subdomain name support e.g. "a.goodexample.com"
  • Hyphenated domain name support e.g. "good-example.com"

Install

$ node install --save firebasepath

Usage

var fbsPath = require('firebasepath');
 
fbsPath.escape('example.com'); // -> example-com
fbsPath.unescape('example-com'); // -> example.com

Test

$ node test

                Domain Name                     Firebase Path
escaped:        'token-mail.io'         ->      'token-mail-io'
escaped:        'codeandpush.com'       ->      'codeandpush-com'
escaped:        'stance.com.ng'         ->      'stance-com-ng'
unescaped:      'token-mail.io'         <-      'token--mail-io'
unescaped:      'codeandpush.com'       <-      'codeandpush-com'
unescaped:      'stance.com.ng'         <-      'stance-com-ng'

Package Sidebar

Install

npm i firebasepath

Weekly Downloads

0

Version

1.0.3

License

MIT

Last publish

Collaborators

  • chinwo