-
Notifications
You must be signed in to change notification settings - Fork 366
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Svelte init #343
Draft
arafays
wants to merge
17
commits into
Melkeydev:main
Choose a base branch
from
arafays:svelte-init
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Svelte init #343
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
6d634d2
Svelte template for go-blueprint
arafays 776bec7
fix: styling for tailwind init
arafays a805b47
fix: old way of click in svelte
arafays 2202619
update docs
arafays 293e837
fix: fix typo and add clarity
arafays b7aac4e
fix: add Svelte to allowed advanced features
arafays 9e72fe5
fix typo
arafays 2f77b7c
update images
arafays efb325d
fix: correct typo in React Vite documentation
arafays 18158ba
fix: remove index.html reference from React and Svelte advanced flag …
arafays c052d76
fix: add Svelte support in create command
arafays aaefa9a
fix: disable Svelte option in advanced choices when Htmx is selected
arafays 9db0d3d
Merge branch 'main' into svelte-init
arafays 6c9f030
fix: consolidating Tailwind and app file handling for React and Svelte
arafays 00576c2
add svelte in tests
arafays 56e364b
Update contributors.yml
arafays d3217f4
fix: update makefile template to handle Svelte option alongside React…
arafays File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
<script lang="ts"> | ||
import svelteLogo from './assets/svelte.svg' | ||
import viteLogo from '/vite.svg' | ||
import Counter from './lib/Counter.svelte' | ||
let message: string = $state(''); | ||
|
||
async function fetchData() { | ||
try { | ||
const response = await fetch('http://localhost:8080/'); | ||
message = await response.text(); | ||
} catch (error) { | ||
console.error('Error fetching data:', error); | ||
} | ||
} | ||
</script> | ||
|
||
<main> | ||
<div> | ||
<a href="https://vite.dev" target="_blank" rel="noreferrer"> | ||
<img src={viteLogo} class="logo" alt="Vite Logo" /> | ||
</a> | ||
<a href="https://svelte.dev" target="_blank" rel="noreferrer"> | ||
<img src={svelteLogo} class="logo svelte" alt="Svelte Logo" /> | ||
</a> | ||
</div> | ||
<h1>Vite + Svelte</h1> | ||
|
||
<p class="read-the-docs"> | ||
Click on the Vite and Svelte logos to learn more | ||
</p> | ||
|
||
<div class="card"> | ||
<Counter /> | ||
<p> | ||
Edit <code>src/App.svelte</code> and save to test HMR | ||
</p> | ||
</div> | ||
|
||
<button class="btn-fetch" onclick={fetchData}> | ||
Click to fetch from Go server | ||
</button> | ||
{#if message} | ||
<div> | ||
<h2>Server Response:</h2> | ||
<p>{message}</p> | ||
</div> | ||
{/if} | ||
|
||
<p> | ||
Check out <a href="https://svelte.dev/docs/svelte/overview" target="_blank" rel="noreferrer">Svelte</a>, the official Svelte app powered by Vite! | ||
</p> | ||
</main> | ||
|
||
<style> | ||
.logo { | ||
height: 6em; | ||
padding: 1.5em; | ||
will-change: filter; | ||
transition: filter 300ms; | ||
} | ||
.logo:hover { | ||
filter: drop-shadow(0 0 2em #646cffaa); | ||
} | ||
.logo.svelte:hover { | ||
filter: drop-shadow(0 0 2em #ff3e00aa); | ||
} | ||
.read-the-docs { | ||
color: #888; | ||
} | ||
.btn-fetch { | ||
background-color: #36b962; | ||
} | ||
</style> |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.