Questions tagged [pagedown]

PageDown is the JavaScript Markdown previewer used on Stack Overflow and the rest of the Stack Exchange network. It includes a Markdown-to-HTML converter and an in-page Markdown editor with live preview.

PageDown is the version of Attacklab's Showdown and WMD as used on Stack Overflow and the other Stack Exchange sites.

It includes a converter that turns Markdown into HTML, a Markdown editor with realtime preview of the generated HTML, and a few useful plugins, e.g. for sanitizing the generated HTML according to a whitelist of allowed tags.

The Markdown converter can be used both in the browser (usually in conjunction with the editor, to display a real time preview), and on the server using Node.JS.

156 questions
3
votes
0 answers

Add new button to PageDown markdown editor

How do I add a new button to the PageDown markdown editor located at http://code.google.com/p/pagedown/? Ideally, the button would create a dialog like that used to add a link or image, but any type of examples would be very helpful.
user1032531
  • 24,767
  • 68
  • 217
  • 387
3
votes
2 answers

Hide buttons on pagedown

I'm using pagedown on my website right now, and it's awesome so far, the only detail is it's not a programming-oriented website, so I'd like to remove the 'code' button. Is there a way I can do it? I tried using CSS to hide the buttons but the html…
gosukiwi
  • 1,569
  • 1
  • 27
  • 44
3
votes
1 answer

Markdown to HTML: script compatible with WSH

There's a Markdown-to-HTML converter at Pagedown project (JS script). My question is: how can I adapt this JS script to WSH (Windows Script Host) usage? I need e.g. js script which can be called by WSH command line: cscript.exe md_to_html.js…
Prog1020
  • 4,530
  • 8
  • 31
  • 65
2
votes
0 answers

pagedown HTML resume - how to increase font size and reduce margins

I am using the pagedown template resume, which is accessible by starting a new R markdown file and choosing "From Template" and "HTML Resume". I have pasted the YAML header below. --- title: "Lijia Yu's resume" author: Lijia Yu date: "`r…
richardgasquet
  • 109
  • 1
  • 6
2
votes
0 answers

Changing the margins of a PDF document in RMarkdown

The default resume template from the pagedown package is visually not very appealing. There are quite white spaces along the borders, the sidebar is too thick, and the font is not appropriate. I guess I should be knowledgeable in CSS to make changes…
e. erhan
  • 61
  • 6
2
votes
1 answer

Change option settings with knit:pagedown::chrome_print in Rmarkdown YAML

I have created a large R Markdown document with many child docs using RStudio to produce output in both HTML and PDF. I added this simple line to the YAML parameters of the document and it does exactly what I need. The entire doc is rendered and…
GGAnderson
  • 1,993
  • 1
  • 14
  • 25
2
votes
1 answer

I'm failing to create a pagedown::chrome_print pdf output from a shiny app which takes parameter inputs and renders the Rmarkdown

I have a rmarkdown file which is built around the {pagedreport} package (an add-on to pagedown). This creates a html and them uses pagedown::chrome_print to convert the html to pdf. The rmarkdown file i have works as planned when I have the…
2
votes
1 answer

How to check if reactive a dataframe exists in session and set value in a list as 'NA' if it does not

I am working on a feature which allows my markdown file to conditionally execute chunks based on a parameters sent from my shiny app. Some information about how this works here: https://shiny.rstudio.com/articles/generating-reports.html Within the…
fullera
  • 164
  • 6
2
votes
1 answer

Using R pagedown package to extract webpages as PDFs without pop-ups and cookie warnings

So a friend of mine has written over 800 articles in a food blog, and I am looking to extract all of these to PDFs so that I can bind them nicely and gift them to him. There are simply too many articles to use Chrome's "Save as PDF" manually, so I…
2
votes
1 answer

R Pagedown resume/cv lowercase letters for title

I am working on creating a resume in R using Pagedown. Currently, the default is to have your name in all capital letters at the top of the first page (e.g. JANE DOE). However, this doesn't look great with my name and I am wondering if there is a…
cianna
  • 43
  • 2
2
votes
1 answer

Django markdown show_preview feature throws an error

I am new using markdown. I tried to use the show_preview = False to implement preview using jQuery instead. class PostForm(forms.ModelForm): content = forms.CharField(widget=PagedownWidget(show_preview=False)) publish =…
EarlyCoder
  • 1,213
  • 2
  • 18
  • 42
2
votes
1 answer

Using pagedown to convert from HTML to pdf in R

Its my first time using pagedown. Could you help me? This is my .Rmd code: --- title: "Table" output: html_document: css: "test.css" --- ```{r} library(knitr) data(iris) kable(iris) ``` This is my .css file: .main-container { …
Laura
  • 675
  • 10
  • 32
2
votes
0 answers

Getting Pagedown to preview markdown and mathjax at the same time?

First i got a js script to update a preview div from Pagedown textarea/Pagedown widget from Django-pagedown, with the code below: MathJax.Hub.Config({ tex2jax: { inlineMath: [['$', '$'], ["\\(", "\\)"]] } }); var timeout; $(function () { …
user9152964
2
votes
1 answer

Pagedown markdown script inserts image url once

I have a modified pagedown markdown markup script for inserting image url to the editor but it works only the first time. I have explained my code with comments