2023-04-26
7274
#react#rust
Ahmad Rosid
150928
107
Apr 26, 2023 ⋅ 25 min read

Build a real-time chat app with Rust and React

Ahmad Rosid Software Developer based in Indonesia. Loves solving problems with technology and sharing it with the world.

Recent posts:

Building a Full-Featured Laravel Admin Dashboard with Filament

Building a full-featured Laravel admin dashboard with Filament

Build scalable admin dashboards with Filament and Laravel using Form Builder, Notifications, and Actions for clean, interactive panels.

Kayode Adeniyi
Dec 20, 2024 ⋅ 5 min read
Working With URLs In JavaScript

Working with URLs in JavaScript

Break down the parts of a URL and explore APIs for working with them in JavaScript, parsing them, building query strings, checking their validity, etc.

Joe Attardi
Dec 19, 2024 ⋅ 6 min read
Lazy Loading Vs. Eager Loading

Lazy loading vs. Eager loading

In this guide, explore lazy loading and error loading as two techniques for fetching data in React apps.

Njong Emy
Dec 18, 2024 ⋅ 5 min read
Deno logo over an orange background

How to migrate your Node.js app to Deno 2.0

Deno is a popular JavaScript runtime, and it recently launched version 2.0 with several new features, bug fixes, and improvements […]

Yashodhan Joshi
Dec 17, 2024 ⋅ 7 min read
View all posts

8 Replies to "Build a real-time chat app with Rust and React"

  1. Hi there, congrats for the excellent article.
    A simple question is how to deploy it? Do I need any specifics on the server side to support rust? Like on Aws? Regards,

  2. Thank you for your kind words! I’m happy to help with your question.

    You can deploy a Rust application as a standalone binary on any server or device that is able to run the binary. This means that you do not necessarily need to have the Rust runtime or any other dependencies installed on the target server or device in order to run your application.

    To deploy a Rust application as a standalone binary, you will need to build your application using the `–release` flag, which will optimize the binary for performance. This will produce a self-contained binary that includes everything necessary to run your application.

    You can then transfer the binary to your target server or device and run it as you would any other executable. This approach allows you to deploy your Rust application to a wide range of environments, including servers, VPSs, and even embedded devices.

    And it is possible to deploy a Rust application using Docker, so you can deploy with kubernetes etc.

    I hope this helps! Let me know if you have any other questions.

  3. I know that those articles are for lead generation, but it would be much more useful if you include in code examples logging to logrocket. Debug info, warnings, errors, log context etc.

  4. I am new to rust so I apologize if this is really obvious how do you start the rust backend? I did some looking and I got mixed answers and figured I’d just ask.

  5. Hello,
    I am stuck with installing diesel…
    This is the error I am getting:
    note: LINK : fatal error LNK1181: cannot open input file ‘sqlite3.lib’

    1. may need to install sqlite3 on your system. ie in ubuntu you can install libsqlite3-dev with apt-get.

    2. i too was stuck.
      had to search for many hours.
      i was working on windows platform.
      so here are the steps:
      1. download Source Code sqlite-amalgamation file
      and unzip in a folder (e.g. c:\anyPath).
      download link https://www.sqlite.org/download.html
      2. download Precompiled Binaries for Windows
      and unzip in the above folder (e.g. c:\anyPath).
      3. press window button and paste “Developer Command Prompt for VS xxx”
      and open that “command shell”
      and go to above folder (e.g. c:\anyPath)
      4. copy paste this command and press enter
      “lib /DEF:sqlite3.def /OUT:sqlite3.lib /MACHINE:x64”
      5. press window button and paste “system environment variables”
      search and open “environment variables”
      and go to “system variables” tab
      and search for “path” in the list of variables
      edit it (double click).
      6. add your folder (e.g. c:\anyPath) under path list and save.

      restart the command prompt (shell)
      a restart will be best
      and start your diesel_cli setup.

      thanks for @Ahmad Rosid for rust tutorial.

  6. How to run this on windows 11 i try but “LINK : fatal error LNK1181: cannot open input file ‘sqlite3.lib'”
    This error comes always i don’t know how to correct this i also try to correct

Leave a Reply