diff options
| author | 8cy <[email protected]> | 2020-04-28 11:29:33 -0700 |
|---|---|---|
| committer | 8cy <[email protected]> | 2020-04-28 11:29:33 -0700 |
| commit | d26097762b11bfb9be0d64fc8b9c47be6b3d9f39 (patch) | |
| tree | 66bdc0043d1314baa136894f0846633c08d23149 | |
| parent | change readme output, v1.0.3 (diff) | |
| download | node-uwufy-d26097762b11bfb9be0d64fc8b9c47be6b3d9f39.tar.xz node-uwufy-d26097762b11bfb9be0d64fc8b9c47be6b3d9f39.zip | |
add >w< and stutter + typings, v1.0.4
| -rw-r--r-- | README.md | 4 | ||||
| -rw-r--r-- | dist/app.d.ts | 2 | ||||
| -rw-r--r-- | dist/app.js | 8 | ||||
| -rw-r--r-- | package.json | 3 | ||||
| -rw-r--r-- | src/app.ts | 6 | ||||
| -rw-r--r-- | test/test.js | 2 | ||||
| -rw-r--r-- | tsconfig.json | 2 |
7 files changed, 21 insertions, 6 deletions
@@ -17,12 +17,12 @@ $ npm install uwufy ```js const uwufy = require('uwufy'); -console.log(uwufy('IF YOU SEE THIS THEN THE UWUFICATION WAS SUCCESSFULL')); +console.log(uwufy('IF YOU SEE THIS THEN THE UWUFICATION WAS SUCCESSFULL!!!')); ``` # Output ```sh -$ IF YOU SEE THIS THEN THE UWUFICATION WAS SUCCESSFUWW +$ I-IF YOU SEE THIS THEN THE UWUFICATION WAS SUCCESSFUWW >w< ``` ## Links diff --git a/dist/app.d.ts b/dist/app.d.ts new file mode 100644 index 0000000..48eb464 --- /dev/null +++ b/dist/app.d.ts @@ -0,0 +1,2 @@ +declare const uwufy: (input: string) => string; +export = uwufy; diff --git a/dist/app.js b/dist/app.js index 036b716..faedfda 100644 --- a/dist/app.js +++ b/dist/app.js @@ -2,7 +2,13 @@ const uwufy = (input) => { input = input.replace(/(?:l|r)/g, 'w'); input = input.replace(/(?:L|R)/g, 'W'); + input = input.replace(/!+/g, ` >w< `); + let f = Math.random() < 0.25; + if (f) { + let c = input.charAt(0); + input = c + '-' + input; + } return input; }; module.exports = uwufy; -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXBwLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vc3JjL2FwcC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEsTUFBTSxLQUFLLEdBQUcsQ0FBQyxLQUFhLEVBQVUsRUFBRTtJQUNwQyxLQUFLLEdBQUcsS0FBSyxDQUFDLE9BQU8sQ0FBQyxVQUFVLEVBQUUsR0FBRyxDQUFDLENBQUM7SUFDdkMsS0FBSyxHQUFHLEtBQUssQ0FBQyxPQUFPLENBQUMsVUFBVSxFQUFFLEdBQUcsQ0FBQyxDQUFDO0lBQ3ZDLE9BQU8sS0FBSyxDQUFDO0FBQ2pCLENBQUMsQ0FBQTtBQUNELGlCQUFTLEtBQUssQ0FBQyJ9
\ No newline at end of file +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXBwLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vc3JjL2FwcC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEsTUFBTSxLQUFLLEdBQUcsQ0FBQyxLQUFhLEVBQVUsRUFBRTtJQUNwQyxLQUFLLEdBQUcsS0FBSyxDQUFDLE9BQU8sQ0FBQyxVQUFVLEVBQUUsR0FBRyxDQUFDLENBQUM7SUFDdkMsS0FBSyxHQUFHLEtBQUssQ0FBQyxPQUFPLENBQUMsVUFBVSxFQUFFLEdBQUcsQ0FBQyxDQUFDO0lBQ3ZDLEtBQUssR0FBRyxLQUFLLENBQUMsT0FBTyxDQUFDLEtBQUssRUFBRSxPQUFPLENBQUMsQ0FBQztJQUN0QyxJQUFJLENBQUMsR0FBRyxJQUFJLENBQUMsTUFBTSxFQUFFLEdBQUcsSUFBSSxDQUFBO0lBQzVCLElBQUksQ0FBQyxFQUFFO1FBQ0gsSUFBSSxDQUFDLEdBQUcsS0FBSyxDQUFDLE1BQU0sQ0FBQyxDQUFDLENBQUMsQ0FBQTtRQUN2QixLQUFLLEdBQUcsQ0FBQyxHQUFHLEdBQUcsR0FBRyxLQUFLLENBQUE7S0FDMUI7SUFDRCxPQUFPLEtBQUssQ0FBQztBQUNqQixDQUFDLENBQUE7QUFDRCxpQkFBUyxLQUFLLENBQUMifQ==
\ No newline at end of file diff --git a/package.json b/package.json index 8797a0b..84b5b91 100644 --- a/package.json +++ b/package.json @@ -1,8 +1,9 @@ { "name": "uwufy", - "version": "1.0.3", + "version": "1.0.4", "description": "An NPM package which allows you to uwufy a given string.", "main": "./dist/app.js", + "types": "./dist/app.d.js", "files": [ "dist/", "LICENSE" @@ -1,6 +1,12 @@ const uwufy = (input: string): string => { input = input.replace(/(?:l|r)/g, 'w'); input = input.replace(/(?:L|R)/g, 'W'); + input = input.replace(/!+/g, ` >w< `); + let f = Math.random() < 0.25 + if (f) { + let c = input.charAt(0) + input = c + '-' + input + } return input; } export = uwufy;
\ No newline at end of file diff --git a/test/test.js b/test/test.js index 8270d62..fdc1a67 100644 --- a/test/test.js +++ b/test/test.js @@ -1,3 +1,3 @@ const uwufy = require('../dist/app.js'); -console.log(uwufy('IF YOU SEE THIS THEN THE UWUFICATION WAS SUCCESSFULL'));
\ No newline at end of file +console.log(uwufy('IF YOU SEE THIS THEN THE UWUFICATION WAS SUCCESSFULL!'));
\ No newline at end of file diff --git a/tsconfig.json b/tsconfig.json index 3bcd644..1bf09fe 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -8,7 +8,7 @@ "allowJs": true, /* Allow javascript files to be compiled. */ "checkJs": true, /* Report errors in .js files. */ // "jsx": "preserve", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */ - // "declaration": true, /* Generates corresponding '.d.ts' file. */ + "declaration": true, /* Generates corresponding '.d.ts' file. */ // "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */ // "sourceMap": true, /* Generates corresponding '.map' file. */ // "outFile": "./", /* Concatenate and emit output to single file. */ |