BLUE
PHP 7.4.33
Path:
/var/www/receipt-app-backend-bitkit.dk/httpdocs/node_modules/dedent
Run
Logout
Edit File
Size: 1.11 KB
Close
/var/www/receipt-app-backend-bitkit.dk/httpdocs/node_modules/dedent/macro.js
Text
Base64
const { MacroError, createMacro } = require("babel-plugin-macros"); const dedent = require("./dist/dedent.js").default; module.exports = createMacro(prevalMacros); function prevalMacros({ babel, references, state }) { references.default.forEach((referencePath) => { if (referencePath.parentPath.type === "TaggedTemplateExpression") { asTag(referencePath.parentPath.get("quasi"), state, babel); } else if (referencePath.parentPath.type === "CallExpression") { asFunction(referencePath.parentPath.get("arguments"), state, babel); } else { throw new MacroError( `dedent.macro can only be used as tagged template expression or function call. You tried ${referencePath.parentPath.type}.`, ); } }); } function asTag(quasiPath, _, babel) { const string = quasiPath.parentPath.get("quasi").evaluate().value; const { types: t } = babel; quasiPath.parentPath.replaceWith(t.stringLiteral(dedent(string))); } function asFunction(argumentsPaths, _, babel) { const string = argumentsPaths[0].evaluate().value; const { types: t } = babel; argumentsPaths[0].parentPath.replaceWith(t.stringLiteral(dedent(string))); }
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 1 × Files: 4
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
dist
DIR
-
drwxr-xr-x
2026-05-06 08:23:46
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
LICENSE.md
1.01 KB
lrw-r--r--
2026-05-06 08:23:46
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
macro.js
1.11 KB
lrw-r--r--
2026-05-06 08:23:46
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
package.json
3.42 KB
lrw-r--r--
2026-05-06 08:23:46
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
README.md
12.70 KB
lrw-r--r--
2026-05-06 08:23:46
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).