A bad pun that turns domains into CNAME files
NPM:
$ npm install john-cname
Yarn:
$ yarn add john-cname
const cname = require('john-cname')
cname('http://cname.cool/', 'build')
// Outputs a properly formatted CNAME file in ./build
Type: string
Domain the CNAME file should contain. Protocols and trailing slashes are automatically removed.
cname('http://cname.cool/', 'build')
// -> cname.cool
Type: string
Path to output the CNAME file.
cname('http://cname.cool/', 'build')
// -> ./build/CNAME
MIT © Nick Pfisterer