Skip to content
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

Uncaught TypeError: Cannot read properties of null (reading 'init') #390

Open
newalway opened this issue Sep 19, 2023 · 1 comment
Open
Labels

Comments

@newalway
Copy link

newalway commented Sep 19, 2023

In file Index.vue

<script setup>
import { defineAsyncComponent , h, ref ,inject,watch ,provide,computed } from 'vue'

const Editor = defineAsyncComponent(() => import ('@tinymce/tinymce-vue'))

</script>

<template>
                        <div class="mb-2">
                            <Editor 
                                    v-model="form.description"
                                    api-key="xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
                                    :init="{
                                    height: 500,
                                    menubar: false,
                                    plugins: [
                                        'lists','link','image','charmap','preview','anchor','searchreplace','visualblocks',
                                        'fullscreen','insertdatetime','media','table','help','wordcount','code'
                                    ],
                                    toolbar:[
                                        'undo redo | casechange blocks | bold italic backcolor | \
                                        alignleft aligncenter alignright alignjustify | \
                                        bullist numlst numlist  checklist outdent indent | removeformat |  code table help '],
                                    keep_styles: false,
                                    style_formats_merge: true,
                                    style_formats: [
                                    { title: 'Unstyled list', selector: 'ul,ol', classes: 'list-none' }
                                        ]
                                    }"
                                    initial-value="Welcome to TinyMCE Vue"
                                />
                        </div>
</template>

Capture

pakage.json
"vue": "^3.2.31"
"@tinymce/tinymce-vue": "^5.1.0",

Laravel 9 + ViteJS + InertiaJS

Copy link

Ref: INT-3229

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants