alosaur/handlebars

Deno bundle bad output - _handlebarsDewDew

Closed this issue · 3 comments

Deno Version: 1.5.3
TypeScript: 4.1

The ouptut of Deno build throws an error when importing Handlebars. The error is....

error: Uncaught ReferenceError: _handlebarsDewDew is not defined
    var handlebars = _handlebarsDewDew()['default'];

Steps to reproduce

  1. Clone https://github.com/burkeholland/oak-express
  2. Bundle the project with the following command....
    deno bundle --unstable app.ts app.build.js
  3. Run the bundled file
    deno run -A --unstable app.build.js

What should happen?

The program should run on port 3000

What happens instead?

The console throws the following error...

error: Uncaught ReferenceError: _handlebarsDewDew is not defined
    var handlebars = _handlebarsDewDew()['default'];

Thank you for this issue.

I think it is a Deno problem because it does not support import as, which is in jspm.
https://dev.jspm.io/npm:handlebars@4.7.6/lib/index.dew.js

import { dew as _handlebarsDewDew } from "../dist/cjs/handlebars.dew.js";

denoland/deno#8285 and denoland/deno#8314

That looks correct. Thank you for the quick response. We can close this issue.

kdy1 commented

Is this fixed with deno 1.5.4?