macoe - Good afternoon. I've updated to Twill 3...
# ❓questions
m
Good afternoon. I've updated to Twill 3 and I'd like to know if the step-by-step process for configuring the block editor is still the same as presented in your YouTube video?

https://www.youtube.com/watch?v=kAcJ5G2GhiA

i
Hi @User It's a bit simpler now and we have new ways of going about it too. Did you review the block editor section of the documentation?
m
I read the documentation, but I ended up following the instructions in the video. So it doesn't work the same way as before anymore?
i
it does, but for example you don't need the part in the twill.php configuration file anymore, and you can use PHP classes now instead of blade files to define your blocks
m
I asked this question because following the step-by-step process didn't work. I'll send you a screenshot to show you what's happening.
The form is not showing up. I created the form in resources/views/twill/blocks/paragraph.blade.php.

https://cdn.discordapp.com/attachments/1100827524877013073/1100832957163376783/image.png

This is the paragraph.blade.php

https://cdn.discordapp.com/attachments/1100827524877013073/1100833201217343488/image.png

This is the form that uses the block editor.

https://cdn.discordapp.com/attachments/1100827524877013073/1100833456499470488/image.png

'block_editor' => [ 'blocks' => [ 'quote' => [ 'title' => 'Quote', 'icon' => 'quote', 'component' => 'a17-block-quote', 'rules' => [ 'quote_text' => 'required' ] ], 'paragraph' => [ 'title' => 'Paragraph', 'icon' => 'text', 'component' => 'a17-block-paragraph', ], 'paragraph_image' => [ 'title' => 'Paragraph & Image', 'icon' => 'image-text', 'component' => 'a17-block-paragraph_image', ], ], 'crops' => [ 'image' => [ 'desktop' => [ [ 'name' => 'desktop', 'ratio' => 16 / 9, 'minValues' => [ 'width' => 100, 'height' => 100, ], ], ], 'tablet' => [ [ 'name' => 'tablet', 'ratio' => 4 / 3, 'minValues' => [ 'width' => 100, 'height' => 100, ], ], ], 'mobile' => [ [ 'name' => 'mobile', 'ratio' => 1, 'minValues' => [ 'width' => 100, 'height' => 100, ], ], ], ], ], ],
This is the twill.php
All the blocks I've created are having the same problem paragraph, 'paragraph_image' and quote
i
alright, these 2 files look fine. you can remove
block_editor.blocks
from your config
m
Ok. I removed it
i
still not showing the form?
m
There's no need to run npm run dev or execute any other command, right? Everything is done automatically, correct?
i
yes, it should show up without running any command
I don't think that's the issue but can you try to use
@twillBlockGroup('app')
instead of
paragraph
m
It's still not being displayed.

https://cdn.discordapp.com/attachments/1100827524877013073/1100835467353665556/image.png

Ok
I did that, but the problem persists.
i
alright, sorry to hear that. a few things you can check/try: - php artisan view:clear - php artisan twill:update - check that your block file doesn't have any syntax error - try removing fields from the block and just type some random text to see if that renders or not
m
When I use the blocks made by you, they work, but the ones I created don't.

https://cdn.discordapp.com/attachments/1100827524877013073/1100837362495393843/image.png

Ok
i
you said you updated to Twill 3, did you mean your application was using Twill 2 before, but it had no blocks yet?
m
Yes
i
ok, I see that your blocks are in the
twill
folder which is correct in Twill 3, and I'm wondering if the issue could be that you still have an
admin
folder?
m
I renamed the admin folders to twill, and I just searched now and saw that there are no more admin folders.
Now that I've checked, in another capsule of my project, the repeater has also stopped working.

https://cdn.discordapp.com/attachments/1100827524877013073/1100840501718040668/image.png

When I updated to Twill 3, I renamed the resources/views/admin and routes/admin.php folders and ran the following code: php ./vendor/area17/twill/upgrade.php
i
alright, thanks for reporting this, we will need to investigate. Any chance you could provide a repository to reproduce privately?
m
Hello, Ifox. I've decided to go back to version 2 of Twill. Now it's working!

https://cdn.discordapp.com/attachments/1100827524877013073/1100887484688248842/image.png

Do you know if there is a version of the display adapted for Bootstrap? I saw that you are using Tailwind classes.
Anyway, thank you very much for helping me.
i
do you mean for the frontend rendering of your blocks? Twill doesn't ship frontend code, that's all up to you. We just used Tailwind for the basic examples in Twill 3 but that's not enforced
m
Yes
i
no problem, happy to help figure out how you can upgrade to twill 3 when you decide to work on that again
yeah again Twill doesn't offer any frontend theme because that's not it's role really, but this may come in the future
m
Alright. Thank you very much!