Coder Social home page Coder Social logo

doytsujin / freya-1 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from marc2332/freya

0.0 1.0 0.0 1.5 MB

Native GUI library for ๐Ÿฆ€ Rust powered by ๐Ÿงฌ Dioxus and ๐ŸŽจ Skia.

Home Page: https://freyaui.dev/

License: MIT License

Shell 0.03% Rust 99.97%

freya-1's Introduction

Freya ๐Ÿฆ€

Freya logo

Discord Server Github Sponsors codecov

Website | Docs | Book | Discord

Freya is native GUI library for Rust powered by ๐Ÿงฌ Dioxus and ๐ŸŽจ Skia.

โš ๏ธ It's currently work in progress and not usable for production, but you can already play with it! You can join the Discord server if you have any question or issue.



fn app(cx: Scope) -> Element {
    let mut count = use_state(cx, || 0);

    render!(
        container {
            height: "20%",
            width: "100%",
            background: "rgb(233, 196, 106)",
            padding: "12",
            color: "rgb(20, 33, 61)",
            label { 
                font_size: "20", 
                "Number is: {count}"
            }
        }
        container {
            height: "80%",
            width: "100%",
            background: "rgb(168, 218, 220)",
            color: "black",
            padding: "12",
            onclick: move |_| count += 1,
            label { "Click to increase!" }
        }
    )
}

Freya

Want to try it? ๐Ÿค”

โš ๏ธ See Environment setup first.

Clone this repo and run:

cargo run --example counter

You can also try freya-template

Usage ๐Ÿ“œ

Add Freya as a dependency via git (it's not published on crates.io yet) in your Cargo.toml:

freya = { git = "https://github.com/marc2332/freya" }
dioxus = { git = "https://github.com/DioxusLabs/dioxus", rev="49c5a5043a16fc82210af146c345793dd448e519", features = ["macro", "hooks"]}

Features โœจ

  • Support for Windows, Linux and MacOS
  • Text, containers, images, svg, etc
  • Headless testing
  • Hot reload
  • Optional DevTools panel
  • Components crate (with theming support)
    • Scroll views
    • Virtualized scroll views
    • Button
    • Slider
    • Switch
    • Dropdown
    • and a few more
  • Keyboard and Mouse events
  • Hooks crate for text editing, animating, theming..

Goals ๐Ÿ˜

  • Performant
  • Low memory usage
  • Lightweight
  • Good developer experience
  • Cross platform

Status โŒš

You can see the tracking issues labeled with the tracking label to know what features are implemented and which ones are not, yet.

MIT License

freya-1's People

Contributors

marc2332 avatar trickypr avatar aspnxdd avatar ealmloff avatar wusyong avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.