• Stars
    star
    250
  • Rank 162,397 (Top 4 %)
  • Language
    Rust
  • License
    Apache License 2.0
  • Created over 3 years ago
  • Updated about 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Minimal Rust HTTP client for both native and WASM

ehttp: a minimal Rust HTTP client for both native and WASM

Latest version Documentation unsafe forbidden Build Status MIT Apache

If you want to do HTTP requests and are targetting both native and web (WASM), then this is the crate for you!

You can try the web demo here (works in any browser with WASM and WebGL support). Uses egui_web.

Usage

let request = ehttp::Request::get("https://www.example.com");
ehttp::fetch(request, move |result: ehttp::Result<ehttp::Response>| {
    println!("Status code: {:?}", result.unwrap().status);
});

The given callback is called when the request is completed. You can communicate the results back to the main thread using something like:

More Repositories

1

egui

egui: an easy-to-use immediate mode GUI in Rust that runs on both web and native
Rust
21,911
star
2

loguru

A lightweight C++ logging library
C++
1,783
star
3

eframe_template

The easy way to make a Rust app with a GUI
Rust
772
star
4

emilib

Loose collection of misc C++ libs
C++
339
star
5

wfc

A C++ port of Wave Function Collapse Tiling
C
304
star
6

imgui_software_renderer

A Software Renderer for Dear ImGui
C++
230
star
7

drop-merge-sort

A novel adaptive sorting algorithm
Rust
164
star
8

Configuru

Experimental config library for C++
C++
137
star
9

ram_bench

A benchmark for random memory accesses
C++
106
star
10

Dual-Contouring

Dual Contoruing implemented in C++
C++
73
star
11

eterm

Exeprimental visual terminal for egui
Rust
69
star
12

sol

Lua + Typesafety = Sol
Lua
65
star
13

puffin_egui

Show puffin profiler flamegraph in-game using egui
44
star
14

hobogo

Rust + WASM experiment
Rust
35
star
15

pga

Experimental type-safe geometric algebra for Rust
Rust
35
star
16

bon

BON - Binary Object Notation
C++
22
star
17

field_interpolation

Field interpolation using finite elements and sparse linear least squares
C++
13
star
18

blog

My personal blog, I Like Big Bits
HTML
9
star
19

sproxel

Fork of http://code.google.com/p/sproxel/
Python
9
star
20

emath

Some 2D/3D math I tend to reuse across projects.
C++
9
star
21

egui_presentation

A presentation about egui, implemented in egui
Rust
9
star
22

userp

Rust formatting tool for clustering use statements
Rust
8
star
23

alignify

Helper script for automatic text alignment
Python
7
star
24

snake_case

A Rust crate for working with snake_case strings
Rust
6
star
25

econtext

Rust crate for fast and simple error context on panics
Rust
5
star
26

egui-pure-glow

Quick test of egui dependencies
Rust
4
star
27

luastrip

Strips Lua files of specific statements. The outputted Lua files are identically formatted to the input, including line numbers even after the skipped statements.
C++
4
star
28

urlbot

irc bot that scan for urls, then print the page title to the channel
Python
3
star
29

emilk

This specifies how my profile at https://github.com/emilk looks.
2
star
30

binandlib

A Rust crate to test if it is possible to make a crate that is both a binary and a library
Rust
1
star
31

rayon_test

Test the use of rayon on Wasm
Rust
1
star
32

webgl

WebGL toys
1
star
33

list_traversal

A benchmark for random memory access
1
star