Code Monkey home page Code Monkey logo

Comments (23)

benweet avatar benweet commented on May 23, 2024

It's not in the road map, sorry. Moreover, I have played with the idea of replacing the editor by ACE or something like that, but it's heavier than a textarea and I'm not sure it's compatible with PageDown.

from stackedit.

DeLaGuardo avatar DeLaGuardo commented on May 23, 2024

Please do not switch to ACE, it's awful.

from stackedit.

Atcold avatar Atcold commented on May 23, 2024

adam-p has done an awesome job about it and his plugin is able to interpret all Github recognised syntaxes. Would it be very difficult to take inspiration from his project?

from stackedit.

benweet avatar benweet commented on May 23, 2024

@Atcold Am I missing a point or you are off-topic?

from stackedit.

Atcold avatar Atcold commented on May 23, 2024

OMG.. Ok, I got confused by the term syntax highlighting.. Sorry about that. Shall I open a new issue then, pointing out the lack (or I'm just blind 😖) of syntax highlighting within a code block?

from stackedit.

benweet avatar benweet commented on May 23, 2024

The code is highlighted in the preview if you use fenced code blocks in your markdown (```) and you have the markdown extra extension/prettify option enabled in the settings.

from stackedit.

Atcold avatar Atcold commented on May 23, 2024

What I am trying to say is that ````lua` and `````, as code block opener, have the same syntax highlight in your app, whereas here on Github (and in adam-p project) the difference is properly recognised

io.read()
io.read()

from stackedit.

benweet avatar benweet commented on May 23, 2024

StackEdit uses Prettify which performs language auto detection. He is using highlight.js and a specific stylesheet I suppose. I suggest you to open a new issue for the support of others highlighting library. You can also create a theme if you want to customize the style in the preview.

from stackedit.

Atcold avatar Atcold commented on May 23, 2024

I understand now. Thank you

from stackedit.

schickling avatar schickling commented on May 23, 2024

👍

from stackedit.

bbhenry avatar bbhenry commented on May 23, 2024

So have your editing content syntax highlighted for "Markdown" is not in the road map?

from stackedit.

benweet avatar benweet commented on May 23, 2024

Not for now, it's not supported by pagedown's editor.

from stackedit.

bbhenry avatar bbhenry commented on May 23, 2024

I am not verse with the code itself. But can you explain why is it not possible to just apply Highlight JS over the editor side just like this project here http://dillinger.io/

Also their left and right panel seems to sync much faster. Is that a performance issue on the StackEdit or is it something we can tweak here?

from stackedit.

benweet avatar benweet commented on May 23, 2024

Hi @bbhenry
First, I'm working on this at the moment and it's not that straight forward. Dillinger relies on ACE editor (which is more than just a textarea) for markdown syntax highlighting, not on Highlight.js.

Regarding scrolling synchronization it's another issue. So please open a new issue.

from stackedit.

bbhenry avatar bbhenry commented on May 23, 2024

Thanks for the explanation. I will open a new issue for the synchronization delay.

from stackedit.

benweet avatar benweet commented on May 23, 2024

Sorry @DeLaGuardo the damage is done.

from stackedit.

bbhenry avatar bbhenry commented on May 23, 2024

@@
@benweet , does that mean we are switching from PageDown to ACE based on your reply to DeLaGuardo?

from stackedit.

benweet avatar benweet commented on May 23, 2024

We are using both ACE and pagedown. I had to fork pagedown to make the whole thing possible.

from stackedit.

bbhenry avatar bbhenry commented on May 23, 2024

@benweet
Since Stackedit now has its foot in ACE, is it possible to implement the same syntax highlighting on the editor side like http://dillinger.io/ ?

from stackedit.

benweet avatar benweet commented on May 23, 2024

Syntax is already highlighted in the editor. The difference is that there is no color in the default theme (only grayscale/italic/bold). You can try the "school" theme if you want some color or implement your own theme.

NOTE: if you don't see any syntax highlighting, you may have disabled ACE in Settings->Mode.

from stackedit.

bbhenry avatar bbhenry commented on May 23, 2024

Ok, I checked the mode and it was on ACE. Changed my theme from "Default" to "Night", reload the page and still don't see colors. Here is a screen shot for you.

stackedit - automated web testing with perl and webdriver

from stackedit.

benweet avatar benweet commented on May 23, 2024

It is highlighted. The titles are bold and white instead of gray, the links are underlined... Again, the only theme with colored syntax highlighting is "school".

from stackedit.

bbhenry avatar bbhenry commented on May 23, 2024

ah, I see. Thanks.

from stackedit.

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.