Code Monkey home page Code Monkey logo

Comments (6)

stevetrader avatar stevetrader commented on August 11, 2024

Has anyone found a workaround for this that doesn't involve js?

from parsedown-extra.

maxfenton avatar maxfenton commented on August 11, 2024

It looks like this is a bug with parsedown using the string placeholder as a literal placeholder, and str_replace-ing that. Would changing placeholder in the parsedown PHP to something like PD_PLACEHOLDER fix the issue? (I'd like a sanity-check before making a pull request.)

        # because we don't want for markup to get encoded
        $DOMDocument->documentElement->nodeValue = 'placeholder';
        $markup = $DOMDocument->saveHTML($DOMDocument->documentElement);
        $markup = str_replace('placeholder', $elementText, $markup);

from parsedown-extra.

erusev avatar erusev commented on August 11, 2024

@maxfenton that's correct, it should be resolved now

from parsedown-extra.

erusev avatar erusev commented on August 11, 2024

@hkdobrev could u have a quick look at the failing build at https://travis-ci.org/erusev/parsedown-extra/jobs/85614579

the failure seems related to late static binding

if the problematic test is too complicated to fix, i'd rather remove it as the instance method, that it tests, is sth that's unlikely to change in future

from parsedown-extra.

hkdobrev avatar hkdobrev commented on August 11, 2024

@erusev It's failing, because ParsedownExtraTest extends ParsedownTest and this way PHPUnit executes both testsuites. I don't think that's needed. However if you really want to keep it this way, we'll need to change the way the TestParsedown.php file is loaded.

from parsedown-extra.

erusev avatar erusev commented on August 11, 2024

it extends ParsedownTest because we want to make sure that "extra" doesn't break the handling the rest of the original syntax

from parsedown-extra.

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.