Skip to content

Conversation

@coolreader18
Copy link
Member

@coolreader18 coolreader18 commented Feb 23, 2019

The selection works, but I'm looking for ideas for what other snippets could be put there. Everything's stored in wasm/demo/snippets/*.py; a separate demo snippet would mean a new .py file in that directory.

@coolreader18 coolreader18 marked this pull request as ready for review February 23, 2019 17:01
@windelbouwman
Copy link
Contributor

You can check this issue, it contains mandelbrot.py:

#352

count = 0
until = 10

print(f"These are the first {until} numbers in the Fibonacci sequence:")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sweet! f-strings!

@coolreader18
Copy link
Member Author

coolreader18 commented Feb 23, 2019

It takes a while to run, for me about 20 seconds, and the page is frozen during that time. It's a good example, though.

@coolreader18
Copy link
Member Author

I think it could be improved by a requestAnimationFrame call, but that would be for another PR to add that as a builtin.

@codecov-io
Copy link

codecov-io commented Feb 23, 2019

Codecov Report

Merging #528 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #528   +/-   ##
=======================================
  Coverage   48.41%   48.41%           
=======================================
  Files          69       69           
  Lines       14375    14375           
  Branches     3591     3591           
=======================================
  Hits         6960     6960           
  Misses       5554     5554           
  Partials     1861     1861

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c675a59...6e8b88e. Read the comment docs.

@windelbouwman windelbouwman merged commit d44f1b3 into RustPython:master Feb 23, 2019
@coolreader18 coolreader18 deleted the multiple-demo-snippets branch February 23, 2019 21:19
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 this pull request may close these issues.

3 participants