eckinox / tinymce-bundle

TinyMCE 6 integration for your Symfony apps and forms
MIT License
20 stars 2 forks source link

CAn't get working with 7.0 #13

Open tiamat71 opened 4 months ago

tiamat71 commented 4 months ago

Hello,

I'm with symfony 7 and i can't get this bundle work. Some js are not loading :

GET http://localhost:8882/assets/bundles/tinymce/ext/tinymce/themes/silver/theme.min.js net::ERR_ABORTED 404 (Not Found) GET http://localhost:8882/assets/bundles/tinymce/ext/tinymce/icons/default/icons.min.js net::ERR_ABORTED 404 (Not Found) GET http://localhost:8882/assets/bundles/tinymce/ext/tinymce/models/dom/model.min.js net::ERR_ABORTED 404 (Not Found)

the main js is loaded : http://localhost:8882/assets/bundles/tinymce/ext/tinymce/tinymce.min-e31c6494646ced50e8102ba871096c71.js

what's wrong with my install ?

i'm with the last version 1.1.0

EmilePerron commented 4 months ago

Hi @tiamat71,

Could you provide snippets of your code where TinyMCE is initialized and used?

tiamat71 commented 4 months ago

hi !

bundles.php

<?php

return [
    Symfony\Bundle\FrameworkBundle\FrameworkBundle::class => ['all' => true],
    Doctrine\Bundle\DoctrineBundle\DoctrineBundle::class => ['all' => true],
    Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle::class => ['all' => true],
    Symfony\Bundle\DebugBundle\DebugBundle::class => ['dev' => true],
    Symfony\Bundle\TwigBundle\TwigBundle::class => ['all' => true],
    Symfony\Bundle\WebProfilerBundle\WebProfilerBundle::class => ['dev' => true, 'test' => true],
    Symfony\UX\StimulusBundle\StimulusBundle::class => ['all' => true],
    Twig\Extra\TwigExtraBundle\TwigExtraBundle::class => ['all' => true],
    Symfony\Bundle\SecurityBundle\SecurityBundle::class => ['all' => true],
    Symfony\Bundle\MonologBundle\MonologBundle::class => ['all' => true],
    Symfony\Bundle\MakerBundle\MakerBundle::class => ['dev' => true],
    Symfony\UX\TwigComponent\TwigComponentBundle::class => ['all' => true],
    Symfony\UX\Autocomplete\AutocompleteBundle::class => ['all' => true],
    Symfonycasts\SassBundle\SymfonycastsSassBundle::class => ['all' => true],
    Eckinox\TinymceBundle\TinymceBundle::class => ['all' => true],
];

in my form :


use Eckinox\TinymceBundle\Form\Type\TinymceType;

.........
    public function buildForm(FormBuilderInterface $builder, array $options): void
    {
        $builder
            ->add('topComment', TinymceType::class, [
                "attr" => [
                    "toolbar" => "bold italic underline | bullist numlist",
                ] ])
            ->add('downComment', TinymceType::class, [
                "attr" => [
                    "toolbar" => "bold italic underline | bullist numlist",
                ] ])
        ;
    }
tiamat71 commented 4 months ago

if i copy the tinymce directory in a public/assets (manualy created) it works ... but the asset may be managed by symfony

Joormann-Media commented 4 months ago

Same here. Had to copy the same way.

EmilePerron commented 1 month ago

Hey @tiamat71 & @Joormann-Media,

I just created a new fork of this repo with some bugfixes and improvements, so I'd suggest moving over to this new forked bundle: https://github.com/EmilePerron/tinymce-bundle

Please open an issue over there if the issue persists.

Cheers!