2025-12-31 10:37:35 +01:00
2025-12-31 10:37:32 +01:00
2025-12-31 10:37:34 +01:00
2025-12-31 10:37:35 +01:00
2025-12-31 10:37:35 +01:00
2025-12-31 10:37:35 +01:00
2025-12-31 10:37:32 +01:00
2025-12-31 10:37:35 +01:00
2025-12-31 10:37:32 +01:00
2025-12-31 10:37:32 +01:00
2025-12-31 10:27:33 +01:00
2025-12-31 10:37:35 +01:00
2025-12-31 10:37:35 +01:00
2025-12-31 10:37:32 +01:00

RadioCast

A lightweight, cross-platform radio player built with Tauri and Vanilla JavaScript. Features local playback and Google Cast integration.

Prerequisites

Before you begin, ensure you have the following installed on your machine:

  1. Node.js: Download Node.js (LTS version recommended).
  2. Rust: Install via rustup.rs.
  3. Visual Studio C++ Build Tools (Windows only): Required for compiling Rust. Ensure "Desktop development with C++" is selected during installation.

Installation

  1. Clone the repository:

    git clone <repository-url>
    cd RadioCast
    
  2. Install dependencies:

    npm install
    
  3. Verify Rust environment: It's good practice to ensure your Rust environment is ready.

    cd src-tauri
    cargo check
    cd ..
    

Development

To start the application in development mode (with hot-reloading for frontend changes):

npm run tauri dev

This command will:

  1. Compile the Rust backend.
  2. Launch the application window.
  3. Watch for changes in src/ and src-tauri/.

Building for Production

To create an optimized, standalone executable for your operating system:

  1. Run the build command:

    npm run tauri build
    
  2. Locate the artifacts: After the build completes, the installers and executables will be found in:

    • Windows: src-tauri/target/release/bundle/msi/ or nsis/
    • macOS: src-tauri/target/release/bundle/dmg/ or macos/
    • Linux: src-tauri/target/release/bundle/deb/ or appimage/

Project Structure

  • src/: Frontend source code (Vanilla HTML/CSS/JS).
    • index.html: The main entry point of the app.
    • main.js: Core logic, handles UI events and communication with the Tauri backend.
    • styles.css: Application styling.
    • stations.json: Configuration file for available radio streams.
  • src-tauri/: Rust backend code.
    • src/main.rs: The entry point for the Rust process. Handles Google Cast discovery and playback logic.
    • tauri.conf.json: Configuration for the Tauri app (window size, permissions, package info).

Customization

Adding Radio Stations

To add new stations, edit the src/stations.json file. Add a new object to the array with a name and stream url:

[
  {
    "name": "My New Station",
    "url": "https://stream-url.com/stream"
  }
]

Adjusting Window Size

To change the default window size, edit src-tauri/tauri.conf.json:

"windows": [
  {
    "width": 360,  // Change width
    "height": 720, // Change height
    "resizable": false
  }
]

Troubleshooting

  • Command tauri not found: Ensure you are running commands via npm run tauri ... or global install @tauri-apps/cli.
  • WebView2 Error (Windows): If the app doesn't start on Windows, ensure the Microsoft Edge WebView2 Runtime is installed.
  • Build Failures: Try running cargo update inside the src-tauri folder to update Rust dependencies.

License

[Add License Information Here]

Description
No description provided
Readme 289 MiB
Languages
JavaScript 44.8%
CSS 31.2%
HTML 13%
Rust 11%