A sequence of three nucleotides in mRNA that specifies a particular amino acid or termination signal during protein synthesis.
Required:
nightlyRustcargo-generateleptosfmt
You need to install:
rustup toolchain install nightly --allow-downgrade– make sure you have Rust nightlyrustup target add wasm32-unknown-unknown– add the ability to compile Rust to WebAssemblycargo install cargo-generate– installcargo-generatebinarycargo install --locked cargo-leptos --version 0.2.20– install the leptos build toolcargo install leptosfmt– install the formatter for theview!macroscargo install stylance-cli- install the stylance cli tool to watch for changes in our css modules
For the end2end tests:
cd end2end && npm i– To install the dev dependenciesnpx playwright install --with-deps– To install the browsers playwright needs
For upgrading to latest leptos:
cargo install cargo-generate,cargo install cargo-leptosandcargo install leptosfmtto upgrade to latest global installs
Fill out the .env.example file and rename it to .env before running the app.
💡 All following commands ae run from the root of this repo
Create a vm with podman and name it codon.
To start the podman container for this app, run:
cd dev/psql-compose && podman machine start codon && podman compose up -d && cd ../..To stop it run:
cd dev/psql-compose && podman compose down && podman machine stop codon && cd ../..Watch for changes in leptos:
cargo leptos watchWatch for changes in styles:
stylance --watch --output-file ./style/bundle.css ./Run the leptos formatter via:
leptosfmt src/**/*.rsYou should also run the biom formatter for all test and css files:
cd end2end && npm run format && cd ..cargo leptos build --releaseWill generate your server binary in target/server/release and your site
package in target/site
TODO
cargo leptos end-to-endcargo leptos end-to-end --releaseIf a test fails it might still have the leptos server running in the background. This will cause the next run to also fail because the IP address and port is already being used:
called `Result::unwrap()` on an `Err` value: Os { code: 48, kind: AddrInUse, message: "Address already in use" }
To avoid this make sure you detect what process is still running and kill it:
λ ps -e|grep codon
52333 ttys032 0:00.09 target/debug/codon # our process with PID we need to kill
52379 ttys042 0:00.00 grep codon # this grep search
λ kill 52333Copyleft (c) 2023 Licensed under the GNU GPL-3.0-or-later.