JS: Add test with wrapper function

This commit is contained in:
Asger F
2024-02-14 21:10:44 +01:00
parent d94d4591da
commit 15bc3c282f
2 changed files with 14 additions and 0 deletions

View File

@@ -0,0 +1,10 @@
function wrap(fn) {
return x => fn(x);
}
function f() {}
export const f1 = wrap(f); // $ method=(pack12).f1
export const f2 = wrap(f); // $ method=(pack12).f2
function g() {}
export const g1 = wrap(g); // $ method=(pack12).g1

View File

@@ -0,0 +1,4 @@
{
"name": "pack12",
"main": "./index.js"
}