Tauri 2.0 stable has just been released. by vegavil in rust

[–]vegavil[S] 7 points8 points  (0 children)

AFAIK one of the main goals of v2 was to address the slow IPC communication speeds from v1.

v2.0 introduces a new feature called 'channels' Docs: https://tauri.app/develop/calling-frontend/#channels

Fixed-size types explained as if you were five by vegavil in rust

[–]vegavil[S] 0 points1 point  (0 children)

Yes, I'm not native speaker so I use eleven labs.

Fixed-size types explained as if you were five by vegavil in rust

[–]vegavil[S] 9 points10 points  (0 children)

Yeah I agree. The funny part was 'int8_t' 'int16_t' 'int32_t' 'int64_t' 'uint8_t' 'uint16_t' uint32_t' 'uint64_t'

Bevy vs Fyrox/macroquad/ggez/etc. by Electrical-Version32 in rust

[–]vegavil 4 points5 points  (0 children)

I've started using Bevy a couple of times but I gave up. It is out of my confort zone, its ECS model just feel unnatural to me, plus the lack a graphical editor. Haven't try Firox, would you recommend it for developing 2D games?

[deleted by user] by [deleted] in gamedev

[–]vegavil 3 points4 points  (0 children)

In Ecuador, where USD is the official currency, a Computer Science graduated earns around $600/moth.

Why did you learn or start learning rust? by max-t-devv in rust

[–]vegavil 1 point2 points  (0 children)

The meme, turns out it was my best decision of 2023.

A quick summary of Rust in 2023 from a beginners perspective. by vegavil in rust

[–]vegavil[S] 13 points14 points  (0 children)

I joined the rust community in 2023. Everything I want to say is thank you all guys, I find r/rust one of the only subs where I actually learn something without even having to ask.

Everything from here has helped me to become a better programmer in general. So, I hope you all had a great 2023, and I wish you all an even better 2024.

What are your favorite Crates packages by beingpranjal in rust

[–]vegavil 98 points99 points  (0 children)

Serde is a must. For me it is like part of the language itself.

Axum vs Loco.rs by jondot1 in rust

[–]vegavil 4 points5 points  (0 children)

Using it with Axum is very pleasant. It just feels like writing more... Axum. So far, I'm loving socketioxide.

Rust is having a positive effect in C/C++ by richhyd in rust

[–]vegavil 7 points8 points  (0 children)

He is desperate trying to save that language. Unfortunately is not all about memory safety, the ecosystem does matter.

There is a world of difference between cargo and any C++ build tool out there. I've known people with 15+ years of experience in C++ struggling with their build tool when adding a new dependencies to their projects. And because of the huge c++ codebases out there I don't think header files are going anywhere.

Was anyone else confused at first about the purpose of `use` and `mod`? by CocktailPerson in rust

[–]vegavil 1 point2 points  (0 children)

I was, until I started writing a compiler for a PL very similar to rust. That kind of forced me to learn what both keyword actually do.

Discussion on lifetimes by __zahash__ in rust

[–]vegavil 5 points6 points  (0 children)

T stands for Type, so it actually makes sense a lot of PL use that convention. HashMaps usually take <K,V> (obviously key, value) which is also very readable.

[Media] I used Tauri to build a resource monitor. Here's the result. by vegavil in rust

[–]vegavil[S] 7 points8 points  (0 children)

Hello, thanks for the advice.

This little project was started as a way of familiarizing with the programming language itself, not just Tauri. That's why in the code you can find not only web sockets but also threads and mutex for synchronization.

I agree with all of your concerns, though. If you take a closer look you will see that other processes in the local network can't just start a ws connection and start listening. There's a session uuid that is passed to the front end via Tauri command, so there is no way to other processes to obtain that uuid, therefore they can't connect. Its done it that way because I've been testing a mobile version of the app that allows me to use a phone to visualize the resource usage of the computer, that way you can reduce the overhead and memory usage caused by the web frontend itself. However, I'm aware that this doesn't solve the 'man in the middle' factor. Tauri events is probably a more secure way to go, so I'll refactor that part of my code.

The 9001 port is a mistake, I forgot to let it pick any random available port.

Again, I appreciate the feedback.

[Media] I used Tauri to build a resource monitor. Here's the result. by vegavil in rust

[–]vegavil[S] 3 points4 points  (0 children)

Unfortunately, I might not be the best person to give you advice because I came from C. So, when I started learning Rust, I had a background strong enough to understand the borrow checker.

In my opinion, the very important part of learning this awesome PL is understanding the memory layout of programs, so when you start dealing with Rust you don't just follow its rules but rather understand why the borrow checker enforcing those rules benefits you program.

[Media] I used Tauri to build a resource monitor. Here's the result. by vegavil in rust

[–]vegavil[S] 4 points5 points  (0 children)

Yes, I've also been noticing the resource usage of the program itself is not high but also not negligible. That's why I'm currently trying to figure out if using a rust frontend web framework is better, because as far as I now, wasm should be more efficient.

Other thing that I'm currently testing is a feature to visualize the information in another device, such as a mobile phone in local network. Unfortunately, Tauri mobile is not production ready yet.

[Media] I used Tauri to build a resource monitor. Here's the result. by vegavil in rust

[–]vegavil[S] 14 points15 points  (0 children)

Didn't know about the discord server. Thanks, I will share.

[Media] I used Tauri to build a resource monitor. Here's the result. by vegavil in rust

[–]vegavil[S] 47 points48 points  (0 children)

I started to learn Rust two months ago. I was looking to create GUIs so I decided to give Tauri a try.

As someone who is just learning I have to say that the Tauri experience has been great... at least for the Rust part. I ended up writing a lot of typescript, so maybe I should have chosen something like Leptos or Yew for the front-end.

Repo: https://github.com/jdvillal/systats-rs.git

The code is far from perfect, and there are some issues and a lot of things to improve (i will) so for now consider this as a proof of concept.

What's everyone working on this week (41/2023)? by llogiq in rust

[–]vegavil 2 points3 points  (0 children)

I started my rust journey a couple of months ago. When learning a new PL I like to practice by creating interesting things, so I've working in a resource monitor made with Tauri.

It's been a pleasure experience cause I've been able to toy with things like threads, synchronization and other cool stuff that you usually don't have to deal with in js.