Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/calvinlfer/tyrian-chartjs-interop-example
This is an example of how to use Chart.JS and integrate it with Tyrian
https://github.com/calvinlfer/tyrian-chartjs-interop-example
Last synced: 4 days ago
JSON representation
This is an example of how to use Chart.JS and integrate it with Tyrian
- Host: GitHub
- URL: https://github.com/calvinlfer/tyrian-chartjs-interop-example
- Owner: calvinlfer
- Created: 2023-07-16T21:18:56.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-07-16T21:21:17.000Z (over 1 year ago)
- Last Synced: 2023-07-16T22:34:51.741Z (over 1 year ago)
- Language: Scala
- Size: 5.86 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Tyrian Chart.JS interop
This is a simple example of how to use [Chart.JS](https://www.chartjs.org)
leveraging [Scalably Typed](https://scalablytyped.org) mappings and getting it
to interop with [Tyrian](https://tyrian.indigoengine.io).## Instructions
This project makes use of the ScalaJS Bundler plugin via ScalablyTyped so all
dependencies (NPM and Scala.JS) are managed by SBT. To transpile Scala JS code
to JavaScript, run:```bash
sbt fastOptJS::webpack
```This will generate
`target/scala-3.3.0/scalajs-bundler/main/myawesomewebapp-fastopt-bundle.js`
which is used by index.htmlYou can use the following to automatically recompile when you change the code:
```bash
sbt ~fastOptJS::webpack
```To run the web application, run:
```bash
npx http-server -c-1
```This starts up a web server on port 8080 and does not cache any files.
Visit the root page to see the application