-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix axum tutorial in makefile #470
Conversation
Please note, this currently only partially fixes #469 - specifically, it fixes the broken build, but the tutorial itself still does not work. This change seems to result in not building or deploying the wasm which may be necessary to run the demo. |
@dpasirst I just tested it and it worked fine on my machine? |
@yaleman - It is possible that I'm doing something wrong. Perhaps to figure this out: would you please clarify how you tested? For example, Are you sure you tested in a 100% clean setup with a git pull to a new location (NOTE: If you start from a completely clean setup and do the following: git clone https://github.com/kanidm/webauthn-rs.git
cd webauthn-rs/tutorial/
make axum The rust code builds and the webserver starts listening, the
|
You're right, I hadn't taken into account having an already-built version, thanks for calling it out - the default feature for axum was set to |
@yaleman - yes, that does get the tutorial working for javascript as long as you go to Two observations:
import init, { run_app } from './wasm.js'; <--- This line
async function main() {
await init('./wasm_bg.wasm'); <--- This line
run_app();
} modify to: import init, { run_app } from './wasm_tutorial.js';
async function main() {
await init('./wasm_tutorial_bg.wasm');
run_app();
} After that change, the wasm tutorial for axum will work too! |
Fixes #469
Remove the wasm build from the axum tutorial, as it defaults to the js display anyway.