- Sveltejs sandbox using RxJS/AJAX to fetch API observable data.
- Note: to open web links in a new window use: ctrl+click on link
- Displays API observable data such as Github user details
- Note: Rxjs 'startWith' used to initialise fetch with an empty array
- Note: Rxjs 'pluck operator deprecated - replaced with map()
- Snowpack frontend build tool, alternative to webpack or Parcel etc.
- Sveltejs/kit v3 fast front-end UI library with small bundles of highly-optimized vanilla JavaScript & declarative transitions. Does not use a virtual DOM.
- RxJS Reactive Extensions JS library
- RxJS/AJAX used to fetch Github API observable
- Github REST API v2 RESTful API with data on all world countries. Get a Github access token so API access not limited
npm i
to install dependenciesnpm run dev
to run dev server on portlocalhost:8080
. Note: I had to checkdev tools/network/Disable cache
to prevent caching and to see changes to filesnpm run build
to build a static copy of app to abuild/
foldernpm run start
to run build files on portlocalhost:8080
- N/A
userCard.svelte
with HTML that has been extended using Svelte-specific syntax.
<main>
<h3>Github User Infomation</h3>
<UserCard {user} />
<br />
<h3>List of repos with links that contain 'svelte'</h3>
{#each $reposObservable as r}
<div>
<a href={r.url}>{r.name}</a>
</div>
{/each}
</main>
- Observables can be displayed in Svelte markup with a preceding $
- Status: Working
- To-Do: Try out more RxJS methods
- This project is licensed under the terms of the MIT license.
- Repo created by ABateman, email: gomezbateman@yahoo.com