Freetube: The FreeTube Rewrite

Created on 16 Feb 2020  路  11Comments  路  Source: FreeTubeApp/FreeTube

Hello Everyone!

As I've mentioned in my last blog post, I've been working on doing a rewrite for FreeTube as the code has become a bit messy in places making it hard to continue with what I have.

I wanted to let you know that the code for the rewrite has been publicly released as of today.

For those of you unaware, you can learn more about the rewrite (along with why it's being done) over at the latest blog post.

Right now it's not in a state of replacing the last release of FreeTube. A lot of features are missing but they will slowly be coming back as progress gets made. Because of this, there are no binaries released at this time, and it is simply a release of the current code base.

I encourage anyone and everyone who is interested in contributing to this code base to check out the code and get involved. Now is a perfect time to get involved since the code base is much smaller and more refined.

This issue is for open discussion where you can ask questions about the rewrite. If you're interested in getting involved, you can check out the Rewrite Repository to learn more.

Discussion

Most helpful comment

The answer is likely going to be yes and no, so let me explain.

As a desktop application, FreeTube will continue to be used along with Electron. I simply do not have the time nor motivation to support multiple platforms (specifically non-Linux platforms) without it. There are a lot of people who use FreeTube and they use it on various platforms. I'd effectively be ignoring half of the current user base if I decided to only focus of Linux based systems.

Having said that, I'm trying to rewrite FreeTube in such a way so that it doesn't rely on many Electron specific APIs so that it could be self-hosted. This would allow a user to use FreeTube in any browser, without it being a separate app. This would also open up the possibility of a potential PWA version which would allow a pseudo installation for Android and iOS. This isn't something I want to promise right away but it's something that I'm keeping in mind as work continues.

I realize it might not be the answer you were looking for, but right now I have to do what is realistically possible for one person while also pleasing the most amount of users as possible. At this point in time, dropping Electron entirely has too many downsides compared to the benefits.

All 11 comments

Any plans of dropping Electron in the future? :eyes:

Any plans of dropping Electron in the future? eyes

I second this, would love for a non electron rewrite of the app

The answer is likely going to be yes and no, so let me explain.

As a desktop application, FreeTube will continue to be used along with Electron. I simply do not have the time nor motivation to support multiple platforms (specifically non-Linux platforms) without it. There are a lot of people who use FreeTube and they use it on various platforms. I'd effectively be ignoring half of the current user base if I decided to only focus of Linux based systems.

Having said that, I'm trying to rewrite FreeTube in such a way so that it doesn't rely on many Electron specific APIs so that it could be self-hosted. This would allow a user to use FreeTube in any browser, without it being a separate app. This would also open up the possibility of a potential PWA version which would allow a pseudo installation for Android and iOS. This isn't something I want to promise right away but it's something that I'm keeping in mind as work continues.

I realize it might not be the answer you were looking for, but right now I have to do what is realistically possible for one person while also pleasing the most amount of users as possible. At this point in time, dropping Electron entirely has too many downsides compared to the benefits.

Just for curiosity: why Vue?
React would have been perfect, faster to develop and easier to find people to work on the project!

Vue is chosen over other frameworks simply because it's what I'm familiar with. I am comfortable with using Vue to the point where I feel like I have a good understanding of proper structure and styling to put together a well thought out app. I have virtually no React experience, which would right away not make this rewrite "faster to develop". There would be a lot of research and learning to make sure that it's done right compared to using Vue.

Having taken a look at React simply to respond to this answer, I can easily say that I much prefer Vue's syntax and structuring over React's. The way that React handles HTML templating within a JavaScript class feels inferior to me compared to Vue adding everything to a <template> tag. I feel that the code is much cleaner this way. This is just one example of what I didn't like. While there's always a possibility of this being biased, but the Vue site has a pretty good comparison with React on their website that I feel is worth reading.

I took a look at these Tic-Tac-Toe example projects written in both Vue and React to make my conclusion. While not shown in this example, Vue has the ability to separate the HTML, JS, and CSS into different files, where this example adds all of it to one file. For the rewrite, I separate them into different files as I believe it's cleaner that way.

I wouldn't necessarily say that simply switching to React would attract more developers. Vue is growing in usage and will likely see no shortage in developers wanting to work with it. As long as I continue to move forward, developers will eventually come to help, regardless of what technologies I use to put it together. I plan on continuing this mindset and FreeTube will still be put together regardless if I'm the only one working on it or not.

I heartily disagree, but I respect your choice, even if reading about React on the Vue's website is maybe not the most objective opinion you can find!

Any plans of dropping Electron in the future? eyes

In case you're interested, I have begun developing my own youtube / invidious frontend, its a very minimal tui interface, only has two dependancies. [https://github.com/djt3/tuitube] Feel free to check it out if you're interested)

Why not just embed everything into an html page and host it online so that we can watch YouTube with freetube in a browser? Is that possible?

Why not just embed everything into an html page and host it online so that we can watch YouTube with freetube in a browser? Is that possible?

This will be possible. Currently it's possible to build FreeTube as a "Static" web site, which essentially means that it doesn't really have to have any server sitting underneath it. It's basic enough that you could simply open it into the web browser on your machine and run it without a server. There would be some missing features with this method though. This would be the only version I could realistically host because anything else would be too much bandwidth usage.

I also have some news about the rewrite. Feel free to take a look at the new updates in the progress blog here

Hey everyone! I have some more news about the rewrite. This news includes some progress updates as well as the official release date! There's some very important information in here so please do take some time to read it when you get the chance.

Check it out here!

The rewrite is tomorrow! We're currently in the process of migrating the work and code over to this repository. As you may have noticed, we're closing many issues that won't be relevant any more due to this release. Since that's the case there isn't any need for this issue to stay open any more. Stay on the lookout for the release tomorrow! I hope you enjoy! :)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Albirew picture Albirew  路  4Comments

linuxgirl22 picture linuxgirl22  路  5Comments

martinmurciego picture martinmurciego  路  6Comments

aproposnix picture aproposnix  路  3Comments

e-buttelli picture e-buttelli  路  3Comments