{"id":1075,"date":"2020-11-24T09:44:58","date_gmt":"2020-11-24T09:44:58","guid":{"rendered":"https:\/\/www.muratyaman.co.uk\/blog\/?p=1075"},"modified":"2020-12-28T14:22:28","modified_gmt":"2020-12-28T14:22:28","slug":"much-needed-reset-to-node-js-world-is-getting-more-stable","status":"publish","type":"post","link":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/2020\/11\/much-needed-reset-to-node-js-world-is-getting-more-stable\/","title":{"rendered":"much needed reset to Node.js world is getting more stable"},"content":{"rendered":"<p>much needed #reset to #node #nodejs world is getting more #stable ! It can run #JavaScript and #TypeScript code; uses Google&#8217;s V8 engine and is built using #Rust ! Go #Deno !<\/p>\n<p><a href=\"https:\/\/deno.land\/\">https:\/\/deno.land\/<\/a><\/p>\n<p>I am going to try on a small project. I know that I have to write &#8220;most&#8221; of the code! :)))<\/p>\n<p>+ I like the way they work with Golang mindset (aiming to have similar std modules as much as possible <a href=\"https:\/\/golang.org\/pkg\/\">https:\/\/golang.org\/pkg\/<\/a> ). Raw source code of dependencies can be downloaded via URLs, into one &#8220;global&#8221; cache (i.e. one instance of node_modules I think). no need for transpiled versions but you can still create &#8220;bundles&#8221; and serve.<\/p>\n<p>+ security is there by default. e.g. you cannot read disk unless you request that permission.<\/p>\n<p>&#8211; dependency management is not great yet, I think, even though they can use import-maps. I don&#8217;t like depending on specific versions &#8220;1.2.3&#8221;, I prefer relying on &#8220;1.x&#8221; of a module, I only care about backward-compatible major version. Otherwise, it will be a mess to maintain. Again!<br \/>\n<a href=\"https:\/\/deno.land\/manual\/linking_to_external_code\/import_maps\">https:\/\/deno.land\/manual\/linking_to_external_code\/import_maps<\/a><br \/>\nif I depend on 5 modules which depend on http module, I could end up running 5 different versions of http module.<br \/>\n&#8220;The basic format of code URLs is https:\/\/deno.land\/x\/IDENTIFIER@VERSION\/FILE_PATH. If you leave out the version it will be defaulted to the most recent version released for the module.&#8221;<br \/>\nmost recent version may break my code if there is a jump like from 1.x to 2.x<br \/>\nif @ version can be any string like a release tag &#8220;v1.x-stable&#8221; then I am happy \ud83d\ude42<\/p>\n<p>&#8211; compatibility module for Node is not complete yet: https:\/\/deno.land\/std@0.78.0\/node<\/p>\n<p>&#8211; many module developers are still porting their code: https:\/\/deno.land\/x<br \/>\nlong long way to go. give it a year, it will be much better!<\/p>\n<p>Ryan was behind Node: <a href=\"https:\/\/github.com\/ry\">https:\/\/github.com\/ry<\/a><br \/>\nso, they have been rewriting it! :)))<\/p>\n","protected":false},"excerpt":{"rendered":"<p>much needed #reset to #node #nodejs world is getting more #stable ! It can run #JavaScript and #TypeScript code; uses Google&#8217;s V8 engine and is built using #Rust ! Go #Deno ! https:\/\/deno.land\/ I am going to try on a small project. I know that I have to write &#8220;most&#8221; of the code! :))) + I like the way they work with Golang mindset (aiming to have similar std modules as much as possible https:\/\/golang.org\/pkg\/ ). Raw source code of dependencies can be downloaded via URLs, into one &#8220;global&#8221; cache (i.e. one instance of node_modules I think). no need for transpiled versions but you can still create &#8220;bundles&#8221; and serve. + security is there by default. e.g. you cannot read disk unless you request that permission. &#8211; dependency management is not great yet, I think, even though they can use import-maps. I don&#8217;t like depending on specific versions &#8220;1.2.3&#8221;, I prefer relying on &#8220;1.x&#8221; of a module, I only care about backward-compatible major version. Otherwise, it will be a mess to maintain. Again! https:\/\/deno.land\/manual\/linking_to_external_code\/import_maps if I depend on 5 modules which depend on http module, I could end up running 5 different versions of http module. &#8220;The basic format of code URLs is https:\/\/deno.land\/x\/IDENTIFIER@VERSION\/FILE_PATH. If you leave out the version it will be defaulted to the most recent version released for the module.&#8221; most recent version may break my code if there is a jump like from 1.x to 2.x if @ version can be any string like a release tag &#8220;v1.x-stable&#8221; then I am happy \ud83d\ude42 &#8211; compatibility module for Node is not complete yet: https:\/\/deno.land\/std@0.78.0\/node &#8211; many module developers are still porting their code: https:\/\/deno.land\/x long long way to go. give it a year, it will be much better! Ryan was behind Node: https:\/\/github.com\/ry so, they have been rewriting it! :)))<\/p>\n","protected":false},"author":2,"featured_media":1076,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[202,203,93,166,201],"class_list":["post-1075","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-technology","tag-deno","tag-golang","tag-javascript","tag-node","tag-typescript"],"_links":{"self":[{"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1075","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/comments?post=1075"}],"version-history":[{"count":2,"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1075\/revisions"}],"predecessor-version":[{"id":1154,"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1075\/revisions\/1154"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/media\/1076"}],"wp:attachment":[{"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/media?parent=1075"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/categories?post=1075"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.muratyaman.co.uk\/blog\/index.php\/wp-json\/wp\/v2\/tags?post=1075"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}