How to validate an array of strings for the upload files in Phoenix LiveView

I tried now this and don’t works.

So is this working?

yes, it worked.

Hi @romenigld, since you did the desk implementation for pragstudio, did you run into this error? It’s somewhat tied to the concept of validation of a form with file uploads.

Hello @PrincetonPoh ,
this was an idea that I had after doing this Deks liveview example.

Then I was thinking about and I remember I read something in the elixirschool and this is the post Elixirschool - Changesets:
Changesets · Elixir School

and I realized on this way, using the changeset.

As you can see I have here:

desk.ex

It is ok with that?
or it has some other function in liveview for better pattern?

desks_live_html.ex

Interestingly, this was the first LiveView course by Praprog.
I am finishing the 2nd version and I finished the Deks Uploads Photos
it changes the :photo_urls for the :photo_locations.

but now with the new version Liveview it uses other functions by the core components.
I will see something.
If someone knows how to do it, please help us!

Thank you for the reply and explanation for your method! Unfortunately I’m also a beginner so I’m waiting for a reply about “best practices” to your comment in my other form post regarding this.