Skip to content

Create SvelteKit example project - #389

Merged
dahlia merged 25 commits into
fedify-dev:mainfrom
2chanhaeng:main
Sep 2, 2025
Merged

Create SvelteKit example project#389
dahlia merged 25 commits into
fedify-dev:mainfrom
2chanhaeng:main

Conversation

@2chanhaeng

Copy link
Copy Markdown
Member

Summary

Create SvelteKit example project.

Related Issue

Changes

  • Create SvelteKit example project at examples/svelte-sample

Benefits

Now new Fedify users who use SvelteKit refer the example.

Checklist

  • [ ] Did you add a changelog entry to the CHANGES.md? Examples are not written in CHANGES.md.
  • [ ] Did you write some relevant docs about this change (if it's a new feature)? Not a new feature.
  • [ ] Did you write a regression test to reproduce the bug (if it's a bug fix)? Not a bug.
  • [ ] Did you write some tests for this change (if it's a new feature)?
  • Did you run deno task test-all on your machine?

Additional Notes

My agent implemented too much (e.g. CSS), but it looks good so I didn't remove it.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Summary of Changes

Hello @2chanhaeng, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request introduces a new SvelteKit example application for Fedify, designed to serve as a practical guide for users looking to integrate Fedify with SvelteKit. The example demonstrates key ActivityPub features and provides a complete, runnable application with modern web development practices, making it easier for developers to get started with building federated applications.

Highlights

  • New SvelteKit Example Project: A comprehensive SvelteKit example application has been added to the examples/sveltekit-sample directory, demonstrating how to build a federated server using Fedify.
  • ActivityPub Integration: The example showcases core ActivityPub functionalities, including actor dispatching, cryptographic key pair management, and handling of 'Follow' and 'Undo' activities.
  • Modern Web Stack: The project is built with SvelteKit and styled using Tailwind CSS, providing a modern and responsive user interface, along with full TypeScript support for type safety.
  • Development and Deployment Guidance: A detailed README.md is included, covering prerequisites, setup, development server instructions, configuration options, usage scenarios, project structure, and deployment considerations.
  • Tooling Configuration: Standard development tooling such as ESLint and Prettier are configured for the new example, ensuring code quality and consistency.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in issue comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@github-actions github-actions Bot added component/integration Web framework integration difficulty/beginner Beginner friendly good first issue Good for newcomers priority/medium labels Aug 29, 2025

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new SvelteKit example project, which is a great addition for new users. The example is comprehensive, covering federation, actor management, and a basic UI. My review focuses on improving code quality, fixing some minor bugs, and ensuring the documentation is accurate and consistent. I've found a few issues, including a critical reference error, some potential runtime errors, and several inconsistencies in the documentation. Addressing these points will make the example more robust and easier for developers to follow.

Comment thread examples/sveltekit-sample/src/lib/federation.ts Outdated
Comment thread examples/sveltekit-sample/src/lib/components/Profile.svelte
Comment thread examples/sveltekit-sample/src/routes/users/[identifier]/posts/+page.server.ts Outdated
Comment thread examples/sveltekit-sample/src/lib/store.ts Outdated
Comment thread examples/sveltekit-sample/src/lib/federation.ts
Comment thread examples/sveltekit-sample/README.md Outdated
Comment thread examples/sveltekit-sample/README.md Outdated
Comment thread examples/sveltekit-sample/src/routes/users/[identifier]/posts/[id]/+page.svelte Outdated
Comment thread examples/sveltekit-sample/src/routes/users/[identifier]/posts/[id]/+page.svelte Outdated
Comment thread examples/sveltekit-sample/src/routes/users/[identifier]/posts/+page.svelte Outdated
Comment thread package.json
@github-actions

github-actions Bot commented Aug 30, 2025

Copy link
Copy Markdown
Contributor

The docs for this pull request have been published:

https://644de684.fedify.pages.dev

dahlia
dahlia previously approved these changes Aug 31, 2025

@dahlia dahlia left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Although I'm not familiar with Svelte, it looks fine in general. @robin-maki Could you review this example code?

@github-actions

Copy link
Copy Markdown
Contributor

The latest push to this pull request has been published to JSR and npm as a pre-release:

Package Version JSR npm
@fedify/fedify 1.9.0-pr.389.1491+bd7c8a25 JSR npm
@fedify/cli 1.9.0-pr.389.1491+bd7c8a25 JSR
@fedify/amqp 1.9.0-pr.389.1491+bd7c8a25 JSR npm
@fedify/cfworkers 1.9.0-pr.389.1491+bd7c8a25 JSR npm
@fedify/denokv 1.9.0-pr.389.1491+bd7c8a25 JSR
@fedify/elysia 1.9.0-pr.389.1491+bd7c8a25 npm
@fedify/express 1.9.0-pr.389.1491+bd7c8a25 JSR npm
@fedify/h3 1.9.0-pr.389.1491+bd7c8a25 JSR npm
@fedify/hono 1.9.0-pr.389.1491+bd7c8a25 JSR npm
@fedify/nestjs 1.9.0-pr.389.1491+bd7c8a25 npm
@fedify/next 1.9.0-pr.389.1491+bd7c8a25 npm
@fedify/postgres 1.9.0-pr.389.1491+bd7c8a25 JSR npm
@fedify/redis 1.9.0-pr.389.1491+bd7c8a25 JSR npm
@fedify/sqlite 1.9.0-pr.389.1491+bd7c8a25 JSR npm
@fedify/sveltekit 1.9.0-pr.389.1491+bd7c8a25 JSR npm
@fedify/testing 1.9.0-pr.389.1491+bd7c8a25 JSR npm

@dahlia
dahlia merged commit f7d7f5f into fedify-dev:main Sep 2, 2025
10 checks passed
@dahlia dahlia added the integration/sveltekit SvelteKit integration (@fedify/sveltekit) label Jan 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

component/integration Web framework integration difficulty/beginner Beginner friendly good first issue Good for newcomers integration/sveltekit SvelteKit integration (@fedify/sveltekit)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Create SvelteKit example project

2 participants