budibase/packages/builder/src/App.svelte

38 lines
582 B
Svelte
Raw Normal View History

2019-07-13 11:35:57 +02:00
<script>
import NoPackage from "./NoPackage.svelte";
import PackageRoot from "./PackageRoot.svelte";
2019-07-31 09:09:04 +02:00
import {store, initialise} from "./builderStore";
2019-07-13 11:35:57 +02:00
import { onMount } from 'svelte';
let init = initialise();
</script>
<main>
{#await init}
<h1>loading</h1>
{:then result}
2019-07-31 09:09:04 +02:00
{#if $store.hasAppPackage}
2019-07-13 11:35:57 +02:00
<PackageRoot />
{/if}
2019-07-31 09:09:04 +02:00
{#if !$store.hasAppPackage}
2019-07-13 11:35:57 +02:00
<NoPackage />
{/if}
{:catch err}
<h1 style="color:red">{err}</h1>
{/await}
</main>
<style>
main {
height: 100%;
width: 100%;
font-family: "Lato", Helvetica, Arial, sans-serif;
}
</style>