Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unble to use bytemd with svelte sapper

See original GitHub issue

Hey , I am new to svelte, found this beautiful rich text editor but I am unable to use it in my app. [rollup-plugin-svelte] The following packages did not export their package.json file so we could not check the "svelte" field. If you had difficulties importing svelte components from a package, then please contact the author and ask them to export the package.json file - bytemd

And i have installed bytemd as a dev dependency

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

CPunishercommented, May 21, 2022

It is recommended to migrate your project to SvelteKit. But if there is some reason, you can take the following steps according to svelterjs/sapper#774:

  1. Installed bytemd as a dev dependency.
  2. Import Editor with
import { Editor } from 'bytemd/dist/svelte-entry';

// or 
import Editor from 'bytemd/dist/editor.svelte';
  1. When you run the development server, you will get an error about missing @rollup/plugin-json. So you should install it as dev dependency, and configure it in rollup.config.js (both client and server).
import json from '@rollup/plugin-json';

export default {
  client: {
    plugins: [
      // ...
  server: {
    plugins: [
      // ...

But I’m not sure there are not other bugs.

github-actions[bot]commented, Jul 30, 2022

This issue was closed because it has been inactive for 7 days since being marked as stale.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Docs • Sapper
Sapper's succesor, SvelteKit, is currently available for use. ... Serialization will fail if the value includes functions or custom classes (cyclical and ...
Read more >
Trying to use bytemd in a SvelteKit app with Vite. - Reddit
Im able to render by appending rehype et al to my svelte.config but my build fails due @sveltejs/adapter-static' .
Read more >
Nested component does not render properly in Svelte/Sapper
I use slug parameters as directory name. The problem I am having is everything except the each loop in taglist. For some reason...
Read more >
bytemd vs SvelteKit - compare differences and reviews?
Compare bytemd vs SvelteKit and see what are their differences. ... SvelteKit fails the maturity test but is something I'd use in a...
Read more >
Things Svelte and Sapper Can't Do (Yet) -
I found a workaround, but it was much, much more verbose. On my Gatsby blog I use MDX to replace markdown elements with...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found