Coder Social home page Coder Social logo

yew-wasm-pack-minimal's People

Contributors

jesperaxelsson avatar jstarry avatar kellytk avatar srounce avatar therustmonk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

yew-wasm-pack-minimal's Issues

Example fails to load: Uncaught (in promise) LinkError

Hi,

Really like Yew so far, but I keep running into a problem where when I tweak something small in the html! macro, and then suddenly see nothing in the browser anymore. Typically this has been something like changing <input /> to ` - suddently nothing renders and I get a 'LinkError' in the console.

I struggled to get a good reproducible example until I tried starting from scratch with this repo and I get a similar problem - no "Hello world" displayed in the browser, and in the browser console I get: Uncaught (in promise) LinkError: import object field '__wbindgen_closure_wrapper287' is not a Function.

Reproduction:

git clone https://github.com/yewstack/yew-wasm-pack-minimal
wasm-pack build --target web
rollup ./main.js --format iife --file ./pkg/bundle.js
python -m http.server 8080

Panic on Initialization

Hi,
I've followed all the instructions and didn't change anything, bit I still get this error:

Encountered a Panic!
Panic error message: attempted to leave type `stdweb::webcore::serialization::SerializedValue` uninitialized, which is invalid

Add a project description

Replace "No description, website, or topics provided." with "A minimal template for starting a Yew project using wasm-bindgen and wasm-pack."

No bundle.js

I cloned the repo installed all the things i think are necessary and get the following errors by

wasm-pack build --target web
[INFO]: Checking for the Wasm target...
[INFO]: Compiling to Wasm...
    Updating crates.io index
.... omitted downloading and compiling of creates ....
[INFO]: Installing wasm-bindgen...
[INFO]: :-) Done in 53.53s
[INFO]: :-) Your wasm pkg is ready to publish at ./pkg.

then started a webserver in the projects root and the Browser is telling me after loading the index.html

Loading failed for the <script> with source “http://localhost:8080/pkg/bundle.js”.

and in fact under /pkg there is no bundle.js like the index.html is trying to load

index.html from the project

<!doctype html>
<html lang="en">

<head>
    <meta charset="utf-8" />
    <title>Yew</title>
    <script src="/pkg/bundle.js" defer></script>
</head>

<body>
</body>

</html>
ls -la pkg
drwxr-xr-x 3 naikon users   4096 24. Nov 19:42 .
drwxr-xr-x 7 naikon users   4096 24. Nov 19:44 ..
-rw-r--r-- 1 naikon users      1 24. Nov 19:42 .gitignore
-rw-r--r-- 1 naikon users   9723 24. Nov 19:42 LICENSE-APACHE
-rw-r--r-- 1 naikon users   1055 24. Nov 19:42 LICENSE-MIT
-rw-r--r-- 1 naikon users    844 24. Nov 19:42 package.json
-rw-r--r-- 1 naikon users   2016 24. Nov 19:42 README.md
drwxr-xr-x 4 naikon users   4096 24. Nov 19:42 snippets
-rw-r--r-- 1 naikon users    149 24. Nov 19:42 yew_wasm_pack_minimal_bg.d.ts
-rw-r--r-- 1 naikon users 152277 24. Nov 19:42 yew_wasm_pack_minimal_bg.wasm
-rw-r--r-- 1 naikon users    427 24. Nov 19:42 yew_wasm_pack_minimal.d.ts
-rw-r--r-- 1 naikon users  26097 24. Nov 19:42 yew_wasm_pack_minimal.js

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.