Code Monkey home page Code Monkey logo

Comments (3)

ije avatar ije commented on May 13, 2024

please use https://esm.sh/html-minifier?no-check instead, the @types/node is very complex to fix to deno, i have a plan to write standalone types for node builtin modules in the future. currently i just implemented the namespce declearation: https://github.com/postui/esm.sh/blob/master/types/node.ns.d.ts

from esm.sh.

timreichen avatar timreichen commented on May 13, 2024

Thank you for your fast reply. That throws a different error concerning require though:

Download https://esm.sh/html-minifier?no-check
Download https://cdn.esm.sh/v27/[email protected]/deno/html-minifier.js?no-check
Download https://deno.land/[email protected]/node/fs.ts
Download https://cdn.esm.sh/v27/[email protected]/deno/stream-http.js
Download https://cdn.esm.sh/v27/_node_buffer.js
Download https://cdn.esm.sh/v27/[email protected]/deno/url.js
Download https://cdn.esm.sh/v27/_node_process.js
Download https://cdn.esm.sh/v27/[email protected]/deno/path-browserify.js
Download https://cdn.esm.sh/v27/[email protected]/deno/https-browserify.js
Download https://cdn.esm.sh/v27/[email protected]/deno/browser.js
Download https://cdn.esm.sh/v27/[email protected]/deno/querystring-es3.js
Download https://cdn.esm.sh/v27/[email protected]/deno/punycode.js
Download https://cdn.esm.sh/v27/[email protected]/deno/buffer.js
Download https://cdn.esm.sh/v27/[email protected]/deno/util.js
Download https://cdn.esm.sh/v27/[email protected]/deno/events.js
Download https://deno.land/[email protected]/node/_fs/promises/mod.ts
Download https://deno.land/[email protected]/node/_fs/_fs_constants.ts
Download https://deno.land/[email protected]/node/_fs/_fs_mkdir.ts
Download https://deno.land/[email protected]/node/_fs/_fs_lstat.ts
Download https://deno.land/[email protected]/node/_fs/_fs_stat.ts
Download https://deno.land/[email protected]/node/_fs/_fs_close.ts
Download https://deno.land/[email protected]/node/_fs/_fs_open.ts
Download https://deno.land/[email protected]/node/_fs/_fs_readFile.ts
Download https://deno.land/[email protected]/node/_fs/_fs_chown.ts
Download https://deno.land/[email protected]/node/_fs/_fs_readdir.ts
Download https://deno.land/[email protected]/node/_fs/_fs_realpath.ts
Download https://deno.land/[email protected]/node/_fs/_fs_access.ts
Download https://deno.land/[email protected]/node/_fs/_fs_copy.ts
Download https://deno.land/[email protected]/node/_fs/_fs_rename.ts
Download https://deno.land/[email protected]/node/_fs/_fs_readlink.ts
Download https://deno.land/[email protected]/node/_fs/_fs_mkdtemp.ts
Download https://deno.land/[email protected]/node/_fs/_fs_unlink.ts
Download https://deno.land/[email protected]/node/_fs/_fs_truncate.ts
Download https://deno.land/[email protected]/node/_fs/_fs_rmdir.ts
Download https://deno.land/[email protected]/node/_fs/_fs_appendFile.ts
Download https://deno.land/[email protected]/node/_fs/_fs_writeFile.ts
Download https://deno.land/[email protected]/node/_fs/_fs_watch.ts
Download https://deno.land/[email protected]/node/_fs/_fs_exists.ts
Download https://deno.land/[email protected]/node/_fs/_fs_chmod.ts
Download https://deno.land/[email protected]/node/_fs/_fs_common.ts
Download https://deno.land/[email protected]/node/_fs/promises/_fs_writeFile.ts
Download https://deno.land/[email protected]/node/_fs/promises/_fs_readFile.ts
Download https://deno.land/[email protected]/node/_utils.ts
Download https://deno.land/[email protected]/node/path.ts
Download https://deno.land/[email protected]/fs/mod.ts
Download https://deno.land/[email protected]/node/buffer.ts
Download https://deno.land/[email protected]/node/events.ts
Download https://deno.land/[email protected]/testing/asserts.ts
Download https://deno.land/[email protected]/async/mod.ts
Download https://deno.land/[email protected]/path/mod.ts
Download https://deno.land/[email protected]/fs/ensure_file.ts
Download https://deno.land/[email protected]/fs/exists.ts
Download https://deno.land/[email protected]/fs/empty_dir.ts
Download https://deno.land/[email protected]/fs/ensure_dir.ts
Download https://deno.land/[email protected]/fs/ensure_link.ts
Download https://deno.land/[email protected]/fs/ensure_symlink.ts
Download https://deno.land/[email protected]/fs/move.ts
Download https://deno.land/[email protected]/fs/copy.ts
Download https://deno.land/[email protected]/fs/expand_glob.ts
Download https://deno.land/[email protected]/fs/eol.ts
Download https://deno.land/[email protected]/fs/walk.ts
Download https://deno.land/[email protected]/testing/_diff.ts
Download https://deno.land/[email protected]/fmt/colors.ts
Download https://deno.land/[email protected]/_util/assert.ts
Download https://deno.land/[email protected]/_util/os.ts
Download https://deno.land/[email protected]/fs/_util.ts
Download https://deno.land/[email protected]/node/_errors.ts
Download https://deno.land/[email protected]/node/_fs/_fs_dirent.ts
Download https://deno.land/[email protected]/encoding/base64.ts
Download https://deno.land/[email protected]/encoding/hex.ts
Download https://deno.land/[email protected]/async/delay.ts
Download https://deno.land/[email protected]/async/mux_async_iterator.ts
Download https://deno.land/[email protected]/async/pool.ts
Download https://deno.land/[email protected]/async/deferred.ts
Download https://deno.land/[email protected]/path/_interface.ts
Download https://deno.land/[email protected]/path/glob.ts
Download https://deno.land/[email protected]/path/common.ts
Download https://deno.land/[email protected]/path/separator.ts
Download https://deno.land/[email protected]/path/win32.ts
Download https://deno.land/[email protected]/path/posix.ts
Download https://deno.land/[email protected]/node/util.ts
Download https://deno.land/[email protected]/path/_constants.ts
Download https://deno.land/[email protected]/path/_util.ts
Download https://deno.land/[email protected]/node/_util/_util_promisify.ts
Download https://deno.land/[email protected]/node/_util/_util_types.ts
Download https://deno.land/[email protected]/node/_util/_util_callbackify.ts
Check file:///example.ts
error: Uncaught ReferenceError: require is not defined
    at https://cdn.esm.sh/v27/[email protected]/deno/html-minifier.js?no-check:7:43918
    at https://cdn.esm.sh/v27/[email protected]/deno/html-minifier.js?no-check:1:875
    at https://cdn.esm.sh/v27/[email protected]/deno/html-minifier.js?no-check:12:296
    at https://cdn.esm.sh/v27/[email protected]/deno/html-minifier.js?no-check:1:875
    at https://cdn.esm.sh/v27/[email protected]/deno/html-minifier.js?no-check:16:204

from esm.sh.

ije avatar ije commented on May 13, 2024

i just updated the server to handle therequire.resolve in node module, but unfortunately it still can NOT work in deno since it needs to read some file in node_modules that does not exist after build.

from esm.sh.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.