Merge pull request #1240 from quantified-uncertainty/1109-fix

note that SquiggleEditorWithImportedBindings is broken (fixes #1109)
This commit is contained in:
Vyacheslav Matyukhin 2022-10-10 12:35:36 +03:00 committed by GitHub
commit bd94e51b31
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3,9 +3,11 @@ title: How to import squiggle files into `.mdx` documents
sidebar_position: 5 sidebar_position: 5
--- ---
import { SquiggleEditorWithImportedBindings } from "../../src/components/SquiggleEditor"; :::caution Proof of concept
_Proof of concept_ The following usage pattern is currently broken. We expect to bring it back in some form in 0.5.1 or 0.5.2 release.
:::
## Consider the following squiggle file ## Consider the following squiggle file
@ -30,10 +32,3 @@ import { SquiggleEditorWithImportedBindings } from "../../src/components/Squiggl
``` ```
Notice, you need to wrap the export of `@quri/squiggle-components` in custom code for dynamicism, please view `packages/website/src/components/` in github for details. Notice, you need to wrap the export of `@quri/squiggle-components` in custom code for dynamicism, please view `packages/website/src/components/` in github for details.
Which would then look exactly like
<SquiggleEditorWithImportedBindings
defaultCode={"f(z)"}
bindingsImportUrl={"/estimates/demo.squiggle"}
/>