Skip to content
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

Cannot build examples/rust-basic #17

Closed
NewGyu opened this issue Oct 21, 2022 · 0 comments · Fixed by #20
Closed

Cannot build examples/rust-basic #17

NewGyu opened this issue Oct 21, 2022 · 0 comments · Fixed by #20

Comments

@NewGyu
Copy link

NewGyu commented Oct 21, 2022

Sorry for the boring point, when running cargo build, the errors below was occurred.

$ cargo build --target wasm32-wasi --release
   Compiling rust-basic v0.1.0 (/workspaces/wasm-workers-server/examples/rust-basic)
error: invalid format string: expected `'}'`, found `'m'`
  --> src/main.rs:19:16
   |
19 |         body { max-width: 1000px; }
   |              - ^ expected `}` in format string
   |              |
   |              because of this opening brace
   |
   = note: if you intended to print `{`, you can escape it using `{{`

I think { and } should be replaced to {{ and }}.

    <style>
        body {{ max-width: 1000px; }}
        main {{ margin: 5rem 0; }}
        h1, p {{ text-align: center; }}
        h1 {{ margin-bottom: 2rem; }}
        pre {{ font-size: .9rem; }}
        pre > code {{ padding: 2rem; }}
        p {{ margin-top: 2rem; }}
    </style>

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant