Join the Webstudio community

Updated 12 months ago

Using Dynamic Data within HTML Blocks

At a glance

The community member is interested in using dynamic data within an HTML block in WebStudio, rather than recreating the HTML structure with blocks. They have experience as a web developer and prefer to reuse their own HTML code. The comments suggest that this is possible but not very comfortable, and the community member would need to use HTML Embed and mix HTML with expressions from a resource. However, the WebStudio team emphasizes that the platform is designed for visual building, and working with HTML templates is not the primary goal. The community member understands this but is looking to understand the platform's capabilities and limitations to make the most of it, even if they need to hire someone for design work.

Hello, I am getting in touch with the platform and watching some YouTube tutorials. I have seen how to use dynamic data but I have a question, is it possible to use dynamic data within an HTML block? Let's say if I already have an html structure created and I want to avoid the work of recreating it with blocks, could I place the html block within a collection and dynamically give it values of texts, images, etc.?
O
R
14 comments
do I understand correctly, you want to use custom html, fetch some json data from an api and render it inside the html you wrote?
Yes, to understand a little more I have been a web developer for more than a decade, and in some cases being able to use or reuse my own code is more accessible to me than generating components from blocks. Imagine, for example, having a list of entries in which you already have in HTML the defined structure of how it should be displayed with what elements, in what positions, etc. In cases like these, what I would be interested in doing is using dynamic data to generate each element (that is, creating a collection where the html blocks are repeated, and each html block, for example, obtains the url of the image from a dynamic value, if possible with titles, extracts, and similar)
Its possible right onw but not very comfortable.
You would have to use HTML Embed and write the html in expression mixed with the variables from resource
I am not quite sure why you would still choose to use webstudio if you don't want to build visually instead of lets say using vercel
Regarding use, what I am looking for is to streamline some processes and solve situations that I previously had with WordPress, such as updates, server management and integrations with third-party services. A few months ago I bought lifetime access to a platform called Kernex from Appsumo that facilitates the creation and management of APIs for headless CMS and my expectation is to be able to use WebStudio to complete this service, having both the back and the front.
What if design is not really my strong point, and I tend to rely a lot on templates and the like that I already have access to. I understand that I could develop the same resources in blocks manually and that this would be ideal to use them in webstudio, but without a doubt that would take me time, not to mention that it is not really an activity that I want to do. I don't rule out hiring someone to do it for me, but first I prefer to make sure what options I have, what their pros and cons are, and then decide.
Well the point of webstudio is to build visually and only use code when necessary, over time needing to code will become less and less.
not being good at design is fine, you can hire someone to make you one
Webstudio, similar to Webflow is built for creators who want to control the design. Working with html templates is not really the goal. But webstudio will have templates you can clone and start from. It has 4 right now in your dashobard and we are launching marketplace soon, which will incentivise others to build them.
I understand the objective of webstudio, and I agree with it, without a doubt the dependence on writing code is something that is increasingly reduced (especially in recent years between the rise of generative AI). Although of course there is still some transition time left, more than anything considering the amount of free direct access resources that can be found online.
yeah, its understandable, that's why we also want to enable copy-pasting tailwind and webflow components
just as of today its not done and we have higher priorities in the builder itself atm
copy-pasting random html/css is problematic, it will be alien to the system and cause pain
I understand that they have a road map to follow, and priorities to cover, as I commented initially, for my part, I am just making contact with the platform and more than anything I am looking to understand what it can do and what it cannot do to know how to get the most out of it. I clarify that I am not looking for a direct solution to be generated for my need, but rather to inform myself and understand how I can use the platform.
Add a reply
Sign up and join the conversation on Discord