@mdworld/homeremote-dockerlist
TypeScript icon, indicating that this package has built-in type declarations

1.9.0 • Public • Published

homeremote-stream-player

Show a list of docker containers and start or stop them

See https://github.com/mdvanes/homeremote/issues/9

How this project was set up

  • nvm use 15
  • copied package.json from other client package in the monorepo
  • yarn lerna add rescript -D --scope=@mdworld/homeremote-dockerlist
  • add bsconfig.json following https://rescript-lang.org/docs/manual/latest/installation#integrate-into-an-existing-js-project
  • add "re:build": "rescript", "re:start": "rescript build -w" to package.json/scripts
  • create a file /packages/dockerlist-client/src/Test.res with the button example from https://rescript-lang.org/try
  • in /packages/dockerlist-client run yarn re:build
  • now get an error that is probably caused because rescript-react is not yet installed, see https://rescript-lang.org/docs/react/latest/introduction
  • compilation indeed does work, when Test.res only contains Js.log("Hello, World!")
  • Add rescript-react: yarn lerna add @rescript/react --scope=@mdworld/homeremote-dockerlist
  • Add { "reason": { "react-jsx": 3 }, "bs-dependencies": ["@rescript/react"] } in bsconfig.json
  • in /packages/dockerlist-client run yarn re:build
  • Add fetch to endpoint: yarn lerna add bs-fetch --scope=@mdworld/homeremote-dockerlist and add to bsconfig.json: "bs-dependencies": ["bs-fetch"]

Running

  • dev: run in root: yarn start and it will start storybook, mock api, and yarn re:start (in this dir)

TODO

Readme

Keywords

none

Package Sidebar

Install

npm i @mdworld/homeremote-dockerlist

Weekly Downloads

7

Version

1.9.0

License

MIT

Unpacked Size

554 kB

Total Files

69

Last publish

Collaborators

  • mdvanes