- Notifications
You must be signed in to change notification settings - Fork0
🏴☠️ Translates text into pirate-speek
License
NotificationsYou must be signed in to change notification settings
spudly/talk-like-a-pirate
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Translates text into pirate-speak.
npm install talk-like-a-pirate
Yonder module exports a function, so all ye have to do be require it in andexecute it. Pass it a string and it will translate it into pirate-lingo for ye.
vartalkLikeAPirate=require('talk-like-a-pirate');console.log(talkLikeAPirate('Hello!'));
All ye have to do here be load ye JavaScript file (use yondertalk-like-a-pirate.js file for web browsers). It putstalkLikeAPirate
on thar window object, so ye just have to call ye function.
<scriptsrc='talk-like-a-pirate.js'></script><script>alert(talkLikeAPirate('Hello!'));</script>
... or use requirejs.
require.config({paths:{'talk-like-a-pirate':'/path/to/talk-like-a-pirate'}});require(['talk-like-a-pirate'],function(talkLikeAPirate){alert(talkLikeAPirate('Hello!'));});
... or better still, use ye node usage described above andbrowserify it.
About
🏴☠️ Translates text into pirate-speek
Topics
Resources
License
Stars
Watchers
Forks
Packages0
No packages published