{"id":22749,"date":"2023-02-28T07:48:59","date_gmt":"2023-02-28T07:48:59","guid":{"rendered":"https:\/\/www.booksofall.com\/id\/?post_type=product&#038;p=22749"},"modified":"2023-02-28T07:48:59","modified_gmt":"2023-02-28T07:48:59","slug":"from-javascript-to-rust-ebook","status":"publish","type":"product","link":"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/","title":{"rendered":"From JavaScript to Rust ebook"},"content":{"rendered":"<h4>Introduction<\/h4>\n<p><strong>A guide to Rust from a node.js developer\u2019s perspective.<\/strong><\/p>\n<p>Each chapter will take concepts you know in <a href=\"https:\/\/en.wikipedia.org\/wiki\/JavaScript#:~:text=JavaScript%20(%2F%CB%88d%CA%92%C9%91%CB%90v,often%20incorporating%20third%2Dparty%20libraries.\">JavaScript<\/a> and node.js and translate them to their <a href=\"https:\/\/www.rust-lang.org\/\">Rust<\/a> counterparts. The first chapters start with the basics, like getting set up with Rust via a tool similar to nvm (rustup), using the package manager (cargo), and setting up <a href=\"https:\/\/code.visualstudio.com\/\">VS Code<\/a>. Later chapters go over language gotchas, how to perform common JavaScript tasks in Rust, and we\u2019ll finish up by touching on solid dependencies to start adding to your projectss.<\/p>\n<p><strong>Wait, why does anyone need to learn anything but JavaScript?<\/strong><\/p>\n<p>I love JavaScript. I\u2019ve been coding JavaScript it since I first saw it in <a href=\"https:\/\/en.wikipedia.org\/wiki\/Netscape\">Netscape<\/a>. I\u2019ve written more lines of JavaScript than any other language. I\u2019m a fan, but I know where the language falls short. It\u2019s fast, but not that fast. It\u2019s easy to write, but easy to screw up. Large projects become unwieldy fast. TypeScript helps scale JavaScript but it adds its own complexity and still doesn\u2019t make anything faster. Server-side JavaScript relies on node.js which is common but not ubiquitous. If you want to distribute something self-contained, there aren\u2019t great answers.<\/p>\n<p>When you start stretching passed what JavaScript is best at, it\u2019s helpful to have another language to turn to.<\/p>\n<p><strong>Why Rust?<\/strong><\/p>\n<p>You could use <a href=\"https:\/\/en.wikipedia.org\/wiki\/C_(programming_language)\">C<\/a>, <a href=\"https:\/\/en.wikipedia.org\/wiki\/C%2B%2B\">C++<\/a>, <a href=\"https:\/\/en.wikipedia.org\/wiki\/C_Sharp_(programming_language)\">C#<\/a>, Go, <a href=\"https:\/\/www.java.com\/\">Java<\/a>, Kotlin, Haskell or a hundred others. Rust is notoriously difficult even for system programmers to get into. Why bother with Rust? Think about your languages as tools in your toolbox. When you fill your toolbox, you don\u2019t want 10 tools that solve similar problems. You want tools that complement each other and give you the ability to fix everything an anything. You already have JavaScript, a developer super-tool. It\u2019s a high level language that\u2019s good enough to run just about everything everywhere. If you\u2019re picking up a new language, you might as well go to the extreme and pick a no-compromise, low-level powerhouse.<\/p>\n<p>Also, WebAssembly.<\/p>\n<p>Rust\u2019s tooling and support for WebAssembly is better than everything else out there. You can rewrite CPU-heavy JavaScript logic into Rust and run it as WebAssembly. Which basically makes you a superhero. With JavaScript and Rust, there\u2019s nothing you can\u2019t handle.<\/p>\n<p><strong>How to use this book<\/strong><\/p>\n<p>This book is not a deep, comprehensive Rust tutorial. It\u2019s meant to bootstrap experienced programmers into Rust. We\u2019ll take common node.js workflows and idiomatic JavaScript and TypeScript and map them to their Rust counterparts. This book balances technical accuracy with readability. It errs on the side of &#8220;gets the point across&#8221; vs being 100% correct. When something is glossed over, we\u2019ll add links for those looking to dive deeper.<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p><iframe style=\"width: 100%; height: 700px; border: none;\" src=\"https:\/\/online.visual-paradigm.com\/share\/book\/from-javascript-to-rust-19tvkxn54p?enforceShowPromotionBar=true&amp;p=1\" frameborder=\"0\" allowfullscreen=\"allowfullscreen\"><\/iframe><\/p>\n","protected":false},"featured_media":22753,"template":"","meta":{"_yoast_wpseo_title":"","_yoast_wpseo_metadesc":""},"product_brand":[],"product_cat":[371],"product_tag":[],"class_list":{"0":"post-22749","1":"product","2":"type-product","3":"status-publish","4":"has-post-thumbnail","6":"product_cat-ruby","8":"first","9":"instock","10":"shipping-taxable","11":"product-type-simple"},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>From JavaScript to Rust ebook - BooksOfAll Indonesian<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/\" \/>\n<meta property=\"og:locale\" content=\"id_ID\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"From JavaScript to Rust ebook - BooksOfAll Indonesian\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/\" \/>\n<meta property=\"og:site_name\" content=\"BooksOfAll Indonesian\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2023\/02\/img_63fdaf978bac5.png\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:image\" content=\"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2023\/02\/img_63fdaf978bac5.png\" \/>\n<meta name=\"twitter:label1\" content=\"Estimasi waktu membaca\" \/>\n\t<meta name=\"twitter:data1\" content=\"2 menit\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/\",\"url\":\"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/\",\"name\":\"From JavaScript to Rust ebook - BooksOfAll Indonesian\",\"isPartOf\":{\"@id\":\"https:\/\/www.booksofall.com\/id\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2023\/02\/img_63fdaf978bac5.png\",\"datePublished\":\"2023-02-28T07:48:59+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/#breadcrumb\"},\"inLanguage\":\"id\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"id\",\"@id\":\"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/#primaryimage\",\"url\":\"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2023\/02\/img_63fdaf978bac5.png\",\"contentUrl\":\"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2023\/02\/img_63fdaf978bac5.png\",\"width\":\"525\",\"height\":\"742\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.booksofall.com\/id\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Categories\",\"item\":\"https:\/\/www.booksofall.com\/id\/categories\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"From JavaScript to Rust ebook\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.booksofall.com\/id\/#website\",\"url\":\"https:\/\/www.booksofall.com\/id\/\",\"name\":\"BooksOfAll Indonesian\",\"description\":\"Biggest IT eBooks library and learning resources - Free eBooks for programming, computing, artificial intelligence and more.\",\"publisher\":{\"@id\":\"https:\/\/www.booksofall.com\/id\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.booksofall.com\/id\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"id\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.booksofall.com\/id\/#organization\",\"name\":\"BooksOfAll Indonesian\",\"url\":\"https:\/\/www.booksofall.com\/id\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"id\",\"@id\":\"https:\/\/www.booksofall.com\/id\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2022\/06\/booksofall-logo-2.png\",\"contentUrl\":\"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2022\/06\/booksofall-logo-2.png\",\"width\":166,\"height\":30,\"caption\":\"BooksOfAll Indonesian\"},\"image\":{\"@id\":\"https:\/\/www.booksofall.com\/id\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"From JavaScript to Rust ebook - BooksOfAll Indonesian","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/","og_locale":"id_ID","og_type":"article","og_title":"From JavaScript to Rust ebook - BooksOfAll Indonesian","og_url":"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/","og_site_name":"BooksOfAll Indonesian","og_image":[{"url":"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2023\/02\/img_63fdaf978bac5.png","type":"","width":"","height":""}],"twitter_card":"summary_large_image","twitter_image":"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2023\/02\/img_63fdaf978bac5.png","twitter_misc":{"Estimasi waktu membaca":"2 menit"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/","url":"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/","name":"From JavaScript to Rust ebook - BooksOfAll Indonesian","isPartOf":{"@id":"https:\/\/www.booksofall.com\/id\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/#primaryimage"},"image":{"@id":"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/#primaryimage"},"thumbnailUrl":"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2023\/02\/img_63fdaf978bac5.png","datePublished":"2023-02-28T07:48:59+00:00","breadcrumb":{"@id":"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/#breadcrumb"},"inLanguage":"id","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/"]}]},{"@type":"ImageObject","inLanguage":"id","@id":"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/#primaryimage","url":"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2023\/02\/img_63fdaf978bac5.png","contentUrl":"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2023\/02\/img_63fdaf978bac5.png","width":"525","height":"742"},{"@type":"BreadcrumbList","@id":"https:\/\/www.booksofall.com\/id\/from-javascript-to-rust-ebook\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.booksofall.com\/id\/"},{"@type":"ListItem","position":2,"name":"Categories","item":"https:\/\/www.booksofall.com\/id\/categories\/"},{"@type":"ListItem","position":3,"name":"From JavaScript to Rust ebook"}]},{"@type":"WebSite","@id":"https:\/\/www.booksofall.com\/id\/#website","url":"https:\/\/www.booksofall.com\/id\/","name":"BooksOfAll Indonesian","description":"Biggest IT eBooks library and learning resources - Free eBooks for programming, computing, artificial intelligence and more.","publisher":{"@id":"https:\/\/www.booksofall.com\/id\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.booksofall.com\/id\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"id"},{"@type":"Organization","@id":"https:\/\/www.booksofall.com\/id\/#organization","name":"BooksOfAll Indonesian","url":"https:\/\/www.booksofall.com\/id\/","logo":{"@type":"ImageObject","inLanguage":"id","@id":"https:\/\/www.booksofall.com\/id\/#\/schema\/logo\/image\/","url":"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2022\/06\/booksofall-logo-2.png","contentUrl":"https:\/\/www.booksofall.com\/id\/wp-content\/uploads\/sites\/12\/2022\/06\/booksofall-logo-2.png","width":166,"height":30,"caption":"BooksOfAll Indonesian"},"image":{"@id":"https:\/\/www.booksofall.com\/id\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/www.booksofall.com\/id\/wp-json\/wp\/v2\/product\/22749","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.booksofall.com\/id\/wp-json\/wp\/v2\/product"}],"about":[{"href":"https:\/\/www.booksofall.com\/id\/wp-json\/wp\/v2\/types\/product"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.booksofall.com\/id\/wp-json\/wp\/v2\/media\/22753"}],"wp:attachment":[{"href":"https:\/\/www.booksofall.com\/id\/wp-json\/wp\/v2\/media?parent=22749"}],"wp:term":[{"taxonomy":"product_brand","embeddable":true,"href":"https:\/\/www.booksofall.com\/id\/wp-json\/wp\/v2\/product_brand?post=22749"},{"taxonomy":"product_cat","embeddable":true,"href":"https:\/\/www.booksofall.com\/id\/wp-json\/wp\/v2\/product_cat?post=22749"},{"taxonomy":"product_tag","embeddable":true,"href":"https:\/\/www.booksofall.com\/id\/wp-json\/wp\/v2\/product_tag?post=22749"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}