Hacker News new | past | comments | ask | show | jobs | submit login
A new cross-platform solution for Web developers (socketsupply.co)
76 points by heapwolf on Dec 9, 2023 | hide | past | favorite | 23 comments



Hello HN! Creator and co-maintainer of the Socket runtime here. This project is new, and it's very ambitious, so I'm here to answer any and all questions. Some of the key take-aways are...

- A focus on Web Devs (No new languages to learn)

- A runtime, not a library (All developer code is encapsulated)

- Provide a secure context that loads like local web server (to make it easy to bring existing code, and use it like a web developer)

- Normalize native platform features like Bluetooth and UDP sockets - Normalize differences between wkwebview and Webview2, and provide things like a unified WHATWG fetch method and URL class.

- Provides new kinds of communication protocols (like P2P)

Please visit the post for more details and give it a star on GitHub to show your support. Cheers!


What target platforms can we use Socket to build for today? “iOS, Android, MacOS, Linux, Windows, and ChromeOS?” - https://socketsupply.co/blog/hello-world/


We officially support iOS, Android, MacOS, Linux, Windows, XBox, Android TV, and unofficially a few others that are in-progress (Apple Watch, ChromeOS). We should definitely put a list somewhere on the site.


Seems like Socket's mobile platform support is more mature than Tauri's to me. Are there other benefits to solo devs or small teams choosing Socket over Tauri beyond that and not having to write Rust to interact with the underlying system?


The development pattern with Socket runtime is dramatically simpler and more secure than Electron or Tauri because we've made the Main process optional. When you build an Electron app, for example, you spend a huge amount of time and energy marshaling data between the UI and the Main process. You end up essentially designing your own routing system. That can be a lot of work to maintain.

In terms of security, an optional Main process means a smaller surface area to worry about when considering your end-user's safety.

Historically, the super strict separation of UI and Main was implemented as a security precaution. For example, you didn’t want the front end doing naughty things to your file system, because after all, who knows when a rouge request might be somehow injected or some data may be unescaped. But in reality it didn't resolve the problem, it just moved the risk into Main - where the same problems still exist, because Main is an arbitrary binary with many most likely unaudited, transient dependencies, and unmitigated access to the OS.

We reduced the overall surface area and locked it down with CSP (a web standard) to granularly control 100% of the native capabilities. In other words, there is less solution-specific ceremony to spend time on, you get to focus on your real problems.


Is Socket compatible with Qwik? Asking here coz Tauri does and has a tutorial on how to use Qwik on Tauri


Yes! It will definitely work in Socket runtime. We don't have an example of how to use Qwick, we have examples of how to use React, Next, Vue since they are some of the most well known frameworks (https://github.com/socketsupply/socket-examples/tree/master/...).

Pretty much any code that runs on the Web will "just work" in Socket.


Looks great!

Since I've never heard anybody prefer React Native to just regular old React, React Native seems kinda pointless now.


P2P connection in the runtime will make a huge difference for apps - outside pressure like this (and React Native) is what ultimately drives the web platform forward.


I have worked with some on the team in a professional setting in the past. I've seen them deliver brilliant enterprise-grade engineering to the Fortune 500. Now they're shaking up the world again. For some reason they're just giving it all away. Take advantage of their generosity. This is pro.


How easy would it be to make a Socket-based GUI program, stick it on a thumb drive and run it on a friend's PC?

The Distribution Guide (https://socketsupply.co/guides/#distribution-guide) has instructions for code signing on Apple platforms, but I'm curious about the "weekend project" angle. Like, does `ssc` produce exe, apk? Could I use it to make a self-contained app that can launch without installation on Linux?


As easy as `ssc build`. You can build for android with: `ssc build --platform android`


Been waiting forever for a tool to make native mobile apps using web tech, looks very promising.


I've been following the project for a bit and this is great, I'm really excited for this to get wider adoption. This is gonna save a lot of headaches and put power in the hands of web devs.


I’ve been trying it for a contract where I have to wrap an existing PWA into a native app. The developer experience is really great!


Do you guys have a tutorial on live p2p video/audio streaming? I wanna check it out!


We dont have a tutorial for that yet, but we have reached a stable point with the p2p protocol and all the foundation has been laid for doing audio and video. Soon we will be releasing an open source project that demonstrates how to use the p2p protocol. You can sign up for the beta here: https://socketsupply.co/relay/


Very Cool! This is going to really speed up development


How I didn't hear about this before? this going to be a game-changer.


Looks cool


great to see continued innovation in this area. especially great to see based around the web. something i have been pushing and trying to build since 2007


Looks great... just getting started :O


Awesome




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: