https://github.com/silvestrevivo/svelte-materialize-posts
SvelteJS app based on the YouTube video-tutorial from @hidjou.
https://github.com/silvestrevivo/svelte-materialize-posts
css3 html5 javascript sveltejs tutorial youtube
Last synced: 3 months ago
JSON representation
SvelteJS app based on the YouTube video-tutorial from @hidjou.
- Host: GitHub
- URL: https://github.com/silvestrevivo/svelte-materialize-posts
- Owner: silvestrevivo
- Created: 2019-06-12T20:55:12.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-03T13:25:24.000Z (over 3 years ago)
- Last Synced: 2025-01-25T14:23:18.379Z (about 1 year ago)
- Topics: css3, html5, javascript, sveltejs, tutorial, youtube
- Language: HTML
- Size: 189 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# svelte-materialize-posts
This proyect is based on the youtube tutorial from @hidjou.
To implement MaterializeCSS in an Svelte3 project, we need to install __rollup-plugin-css-only__ to inject new CSS code coming from another libraries.
On _rollup.config.js_ file we need to include:
```js
plugins: [
//.....
css({output: 'public/extra.css'}),
//.....
],
```
An then in the _App.svelte_ file:
```js
import "../node_modules/materialize-css/dist/css/materialize.min.css";
import "../node_modules/materialize-css/dist/js/materialize.min.js";
```
## Get started
Clone the repo
```bash
cd svelte-materialize-posts
npm install
```
...then start [Rollup](https://rollupjs.org):
```bash
npm run dev
```
Navigate to [localhost:5000](http://localhost:5000). You should see your app running.
## Deploying to the web
### With [now](https://zeit.co/now)
Install `now` if you haven't already:
```bash
npm install -g now
```
Then, from within your project folder:
```bash
now
```
As an alternative, use the [Now desktop client](https://zeit.co/download) and simply drag the unzipped project folder to the taskbar icon.
### With [surge](https://surge.sh/)
Install `surge` if you haven't already:
```bash
npm install -g surge
```
Then, from within your project folder:
```bash
npm run build
surge public
```