Coder Social home page Coder Social logo

Comments (7)

Shaun2D2 avatar Shaun2D2 commented on August 29, 2024

@chrisvidal I don't think this is currently supported, it sounds like your trying to mix blade and markdown together? I looked over the docs http://jigsaw.tighten.co/docs/markdown/ and looks like you have to extend the template directly in the markdown.

from jigsaw.

damiani avatar damiani commented on August 29, 2024

@chrisvidal: @Shaun2D2 is correct regarding the current build...Markdown files require a YAML header which specifies a Blade template to extend, and the @include directive will only pick up .blade.php files. Does the content need to be in Markdown? If it's just plain text or HTML, you could store the content in _content/content-privacy.blade.php and @include that file in multiple places.

There are, however, some new features coming just around the corner that will give you several other ways to accomplish this. Can you give some more details about how your lightbox needs to access the content? Is it via javascript?

from jigsaw.

chrisvidal avatar chrisvidal commented on August 29, 2024

thanks guys !
right now, it is a standard modal lightbox fully include in the page HTML,
then a js lib will toggle this modal.
The requirement is to have only one location to store a md content, in my case the privacy policy of the website client.
and i need to be able to display this privacy content from different context, meaning different layout and page in my case.
to give full example :
simple page : https://www.wootag.com/privacy-policy/
register page with the modal : https://www.wootag.com/signup/

my 1st version was using a blade template, with all the html markup, but when the client asked me to update this content, i lost quite a lots of time, hence i switch to markdown.
the content is easier to manage in a markdown way, because this is purely content in this case, easier to update (frequnce of privacy and terms update are about every 2-3 weeks)

Does this make sense ?
open to any suggestions

from jigsaw.

damiani avatar damiani commented on August 29, 2024

There's an update coming within a week or so that will give you a few options for doing this, including your original approach—the ability to @include and parse that markdown file (and a variety of other file types, for that matter) directly in your privacy-policy.blade.php template, and again in your lightbox template. I'll notify you when those enhancements are live.

from jigsaw.

chrisvidal avatar chrisvidal commented on August 29, 2024

sounds like a good plan ! thanks !

from jigsaw.

erickpatrick avatar erickpatrick commented on August 29, 2024

This one can be closed.

from jigsaw.

damiani avatar damiani commented on August 29, 2024

Added support for @include-ing a Markdown file in v1.0.0

from jigsaw.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.