deno for nodejs dev #14833
elycheikhsmail
started this conversation in
Ideas
deno for nodejs dev
#14833
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
deno for nodejs developer
As a reminder :
nodejs does not support esm by default but deno does
nodejs does not support ts by default it needs a tool like tsc but deno supports ts of the box.
in the js ecosystem we have several options:
write the code in js or ts
write our code to be executed by deno or node (we are not talking about the browser here)
Obviously there is another option.
for this I define js-node, js-node and js-node-after-deno-build-tools as follows:
a javascript code can be written to be executed by node let's call the js-node.
in this case we only need node runtime install.
JavaScript code can be written to be executed by deno let's call it js-deno.
in this case you only need deno runtime install.
a typescrypt code can be written to be compiled by deno tools and executed by node with the possibility of accessing all the node api clet's all it js-node-after-deno-build-tools.
in this case we need both deno and node runtime
advantage:
remark:
I know there is dnt a tool that allows to publish an esm in npm registry but the approach I quoted above allows the same benefits but without npm or any other package entering the process of dev
Beta Was this translation helpful? Give feedback.
All reactions