Use with Django

Has anyone here used Bootstrap Studio in conjunction with Django development? I bought bootstrap studio for some web work before and was wondering if I might be able to use this to help with my Django program.

I'm using a custom export script to add Django template markup to BSS pages. For example,

<div class="item" dj-for="i in items">
  <h2 dj-ref="">This is the heading</h2>
  <div dj-ref="i.content|markdown">Lorem ipsum dolor sit amet …</div>


{% for i in items %}
  <div class="item">
    <h2>{{ }}</h2>
    <div>{{ i.content|markdown }}</div>
{% endfor %}

This means I get to do design in Bootstrap Studio, with fake page content that looks good in BSS, but it is easy to move from BSS to Django templates where real content from the site will be inserted instead. It was fairly straightforward to write the export script in Python based on BeautifulSoup. Works pretty well for me.

Dear Anslem,

Am very new to the Django development. Its exciting to know that you are integrated Django with Bootstrap in exporting. Kindly share the export script which you used. -Mahesh

Dear anselm, I am looking for your assistance, as soon as possible.

For anyone who is interested I have created a github repo so that we can share and expand on the code. I've added ability to create django if and block statements statements. Please raise a ticket in GitHub for future improvements. PRs welcome!

I have been learning how to do something similar in a "testing environment" for integrating a CMS. I am actually using the link component feature of Bootstrap Studio save sections of code to a sub folder called templates which contain each block of code sections on a page I will make to dynamically update. After export, I use B Soup to parse the html templates, remove everything from the page except the block, and update, change, modify, append etc using all the wonderful option of B Soup. The nice thing about this is that any changes to my main project page is linked to the component page which also gets update everytime I export. I have one python script for the main pages that add lines of code to the top of the pages and changes designated links from html to php as well as stripping the code blocks that will be replaced by the php calls. The pages are converted to php extensions also on save.

I also apply beautify to the html or php files so everything comes out looking well formatted and nice looking too.

Soup is amazing.

Wow, this is very interesting !

I'll take a look on your script ! I'm using Flask with Jinja (almost the same template engine).

After the script is run, are the files exported all you need to move into a django project and have going or do you still need to work out the view model and such?

Alternative to blingster repo,

Will also move created files inside a django application folder.