Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/hmsk/elm-vite-plugin-helper
An Elm package to provide helpers for using vite-plugin-elm
https://github.com/hmsk/elm-vite-plugin-helper
elm vite
Last synced: 5 days ago
JSON representation
An Elm package to provide helpers for using vite-plugin-elm
- Host: GitHub
- URL: https://github.com/hmsk/elm-vite-plugin-helper
- Owner: hmsk
- License: mit
- Created: 2022-03-31T06:26:04.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-04-05T04:28:30.000Z (over 2 years ago)
- Last Synced: 2024-12-16T15:15:16.418Z (10 days ago)
- Topics: elm, vite
- Language: Elm
- Homepage: https://package.elm-lang.org/packages/hmsk/elm-vite-plugin-helper/latest
- Size: 3.91 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# elm-vite-plugin-helper
An Elm package to provide helpers for using [vite-plugin-elm](https://github.com/hmsk/vite-plugin-elm).
## Install
```
elm install hmsk/elm-vite-plugin-helper
```## Usage
```elm
import Html exposing (Html, img)
import Html.Attributes exposing (src)
import VitePluginHelper exposing(asset)view : Model -> Html Msg
view _ =
[
img [ src <| asset "/assets/logo.png" ] []
-- An exact URL or inline data for an asset should be provided by Vite
]
```