Code Monkey home page Code Monkey logo

Comments (6)

ebebbington avatar ebebbington commented on August 22, 2024 1

@Jictyvoo it would need to be discussed first, but I personally think we’ll end up going with it as it seems to be the only solution

from deno-drash-middleware.

crookse avatar crookse commented on August 22, 2024 1

@Jictyvoo , the fix for this will be released in the next 24 hours. stay tuned!

from deno-drash-middleware.

ebebbington avatar ebebbington commented on August 22, 2024

I believe this is because Deno.compile isn't converting the export lines. @Jictyvoo the resulting file only shows the contents of one file because the compiled file has errors when it's compiled, whcih are:

  1. const B = new B() will not work (same goes for other files, external issue), and must be changed to const b = new B().
  2. Deno.compile isn't converting export syntax (external/internal issue)

Currently checking if Deno.compile is acting as it should

i think this highlights that we should throw errors in more cases, such as these so it doesn't 'look like' everything went ok when the server is ran, when in reality, it didn't

FYI The errors seen are from viewing the console in the browser - You can see the compild result by running Deno.compile in the deno repl

from deno-drash-middleware.

ebebbington avatar ebebbington commented on August 22, 2024

UPDATE: Seems both Deno.compile and Deno.transpileOnly won't strip exports, essentially not making them browser compatible - @crookse i think we might have to go with https://doc.deno.land/builtin/unstable#Deno.bundle

from deno-drash-middleware.

ebebbington avatar ebebbington commented on August 22, 2024

@Jictyvoo for the time being, you might have to use deno bundle to manually transpile the files

from deno-drash-middleware.

Jictyvoo avatar Jictyvoo commented on August 22, 2024

@ebebbington thanks for the support.
On my example const B = new B() was incorrect, is b sorry for the error.
Will you update the middleware to use Deno.bundle?

from deno-drash-middleware.

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.