Skip to content

Stacks Editor outside the Stack Overflow ecosystem #504

Description

@projct1

Very nice editor, but have a problem. Now, if I include editor styles, all styles in my project are broken.
<style scoped> doesn't help (the styles aren't applied to the editor).
Is it possible to use Stacks Editor outside the Stack Overflow ecosystem? My project is built on Nuxt + Tailwind.

<script setup>
import { StacksEditor } from '@stackoverflow/stacks-editor'

const editor = useTemplateRef('editor')

onMounted(() => new StacksEditor(editor.value, "*Your* **markdown** here"))
</script>

<template>
  <div ref="editor"></div>
</template>

<style>
@import '@stackoverflow/stacks-editor/dist/styles.css';
@import '@stackoverflow/stacks';
@import '@stackoverflow/stacks/dist/css/stacks.css';
</style>

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions