# Website via Franklin.jl from Pluto.jl notebooks

**URL:** <https://discourse.julialang.org/t/website-via-franklin-jl-from-pluto-jl-notebooks/55703>\
**Category:** General Usage\
**Tags:** question, website, pluto, franklin\
**Created:** [February 21, 2021, 12:06am UTC](https://discourse.julialang.org/t/website-via-franklin-jl-from-pluto-jl-notebooks/55703 "2021-02-21T00:06:24Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Stefan\_Bringuier](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stefan_bringuier/32/20132_2.png) [@Stefan\_Bringuier](https://discourse.julialang.org/u/Stefan_Bringuier)\
**Post date:** [February 21, 2021, 12:06am UTC](https://discourse.julialang.org/t/website-via-franklin-jl-from-pluto-jl-notebooks/55703/1 "2021-02-21T00:06:24Z")

</div>

I have a collection of [Pluto.jl](https://github.com/fonsp/Pluto.jl) notebooks that I’ve been putting together for solving science problems using [SymPy.jl](https://github.com/JuliaPy/SymPy.jl). The collection of notebooks is a git repo with a Project.toml and Manifest.toml. I want to turn these Pluto.jl notebook files into a static website using [Franklin.jl](https://franklinjl.org/) and deploy them to the repos github-pages.

Conceptually I see how things should go, but I’m not sure how to execute the workflow to make it work. What should the layout of the repo? Also seems like I need to use Literate.jl however I don’t think it is compatible with the markdown used by Pluto.jl.

Any ideas are much appreciated!

---

<div class="post-metadata">

**Author:** ![lungben](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/lungben/32/12314_2.png) [@lungben](https://discourse.julialang.org/u/lungben)\
**Post date:** [February 21, 2021, 8:07am UTC](https://discourse.julialang.org/t/website-via-franklin-jl-from-pluto-jl-notebooks/55703/2 "2021-02-21T08:07:50Z")

</div>

@fonsp buit a great interactive website with Pluto:  
[https://computationalthinking.mit.edu/Spring21/week1/](https://computationalthinking.mit.edu/Spring21/week1/)

Maybe something like this would also be an option for you.

---

<div class="post-metadata">

**Author:** ![tlienart](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tlienart/32/7640_2.png) [@tlienart](https://discourse.julialang.org/u/tlienart)\
**Post date:** [February 21, 2021, 8:39am UTC](https://discourse.julialang.org/t/website-via-franklin-jl-from-pluto-jl-notebooks/55703/3 "2021-02-21T08:39:51Z")

</div>

I’m not very familiar with Pluto but since it can generate (or is backed by) raw Julia files, these can be used as base for Franklin.

Effectively all you have to do is write a Julia function that « parses » the Pluto script and is able to separate the Julia code cells (and fence them with ````! ... ````) and strip the rest from the symbols that Pluto uses to denote text. This function can then become a « lx fun » that you would call like `\pluto{path/to/file}` in a markdown file (similar to the literate command)

That function will inject the markdown that Franklin will handle, the back ticks and exclamation mark will inject the code, run it and inject the result. (And when you push to GitHub it’ll do the same, assuming your environment is specified properly)

I can help you build a small poc for the function mentioned above if you’d like, feel free to open an issue on Franklin and we can discuss that further there

(Ps: the base of the site computationalthinking is made in Franklin btw 😄)

---

<div class="post-metadata">

**Author:** ![tlienart](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tlienart/32/7640_2.png) [@tlienart](https://discourse.julialang.org/u/tlienart)\
**Post date:** [February 21, 2021, 11:32am UTC](https://discourse.julialang.org/t/website-via-franklin-jl-from-pluto-jl-notebooks/55703/4 "2021-02-21T11:32:40Z")

</div>

I had a bit more of a look, it seems that [GitHub - vdayanand/Jupyter2Pluto.jl](https://github.com/vdayanand/Jupyter2Pluto.jl) has a `pluto2jupyter` function that allows to convert a Pluto script into a Jupyter notebook (I haven’t tried) but so if you can do that then you can go one step further and go from Jupyter to Literate (e.g. via [GitHub - oxinabox/ipynb2LiterateJulia: NBConverter stuff to convert Jupyter Notebooks in to Julia Literate.jl files (This is the opposite of Literate.jl)](https://github.com/oxinabox/ipynb2LiterateJulia)) and then you wouldn’t have to code anything yourself.

---

<div class="post-metadata">

**Author:** ![Stefan\_Bringuier](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stefan_bringuier/32/20132_2.png) [@Stefan\_Bringuier](https://discourse.julialang.org/u/Stefan_Bringuier)\
**Post date:** [February 21, 2021, 5:31pm UTC](https://discourse.julialang.org/t/website-via-franklin-jl-from-pluto-jl-notebooks/55703/5 "2021-02-21T17:31:08Z")

</div>

@tlienart thanks I think I’ll give this route a try first.

---

<div class="post-metadata">

**Author:** ![Stefan\_Bringuier](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stefan_bringuier/32/20132_2.png) [@Stefan\_Bringuier](https://discourse.julialang.org/u/Stefan_Bringuier)\
**Post date:** [February 21, 2021, 5:31pm UTC](https://discourse.julialang.org/t/website-via-franklin-jl-from-pluto-jl-notebooks/55703/6 "2021-02-21T17:31:52Z")

</div>

Thanks for the reference, this will help me think about how to do things.

---

<div class="post-metadata">

**Author:** ![TheCedarPrince](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/thecedarprince/32/17323_2.png) [@TheCedarPrince](https://discourse.julialang.org/u/TheCedarPrince)\
**Post date:** [July 13, 2021, 12:25pm UTC](https://discourse.julialang.org/t/website-via-franklin-jl-from-pluto-jl-notebooks/55703/7 "2021-07-13T12:25:08Z")

</div>

Out of curiosity, has hosting a website of Pluto notebooks been “solved” or addressed? Thinking about doing something similar. Thanks!

EDIT: Seems like this is a good tutorial: [How to Publish Pluto.jl Notebooks Online (with Interactivity!)](https://cotangent.dev/how-to-publish-pluto-jl-notebooks-online-interactively/)
