Skip to content
Branch: master
Go to file
Code

Latest commit

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
src
 
 
 
 
www
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

bigprimes.net

Serverless Rust with Web Assmebly.

Rust Codecov branch Build Status

Setup your local dev environment

  1. Clone bigprimes.net git clone https://github.com/craigmayhew/bigprimes.net.git
  2. Install cargo rustc, rustup curl https://sh.rustup.rs -sSf | sh
  3. Install wasm-pack curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
  4. If developing on Ubuntu, apt-get update && apt-get install libssl-dev npm pkg-config
  5. Install npm npm install npm@latest -g

Setup project for the first time

Unless you are the author of this repo, you almost certainly do not need to do these!

  1. npm init wasm-app www
  2. cd www && npm install && npm audit fix

Contributing

  1. Write code
  2. Run tests
  3. Create PR

Build

  1. Compile rust into wasm wasm-pack build
  2. Build web app cd www && npm install
  3. Build command Craig has been using: cd /mnt/c/Users/user/Documents/GitHub/bigprimes.net/ && RUST_BACKTRACE=1 wasm-pack build --release && cp pkg/* www/pkg/ && cd www && npm install && npm start

Fun Facts

  • there are 1.4*10297 primes smaller than 300 digits
  • there is always a prime between n^2 and (n+1)^2.

Thanks

About

An entirely procedurally generated single page web app, written exclusively in rust and compiled to WebAssembly

Topics

Resources

License

Sponsor this project

Learn more about GitHub Sponsors
You can’t perform that action at this time.