jshimko / meteor-ghostdown

A split-pane Markdown editor by the fine folks at Ghost.org
36 stars 7 forks source link

Pre-populating the MarkDown area everytime( For PostEdit function ) #8

Open abhisheksoni27 opened 9 years ago

abhisheksoni27 commented 9 years ago

I have postList, and EveryPost has its own id and a button which goes to the editpost page, which is using the ghostdown package, and pre-populates it with values stored in the collection.

RIght now, I am using Iron Router to pass theid of the post on click, and then passing values using {{ }} syntax.

But, since I am using {{> GhostEditor}}, I cannot prepopulate it with value provided by the Posts.helpers.

How can this be achieved?

The problem is simple:

Posts Collection has both the markdown and the html.

When edit is pressed, Both title and Body value(markdown) should be passed and pre-populated on the editor page.

jshimko commented 9 years ago

Yeah, this has been on my to-do list for a while. I used to be the only person using this package, so I didn't add much extra functionality. But it seems like a lot more people are starting to use it now, so I'll look into making it more flexible for common use cases. Give me a few days to figure out what makes the most sense. I'll probably end up making two versions - one for Autoform and one for regular form usage.

abhisheksoni27 commented 9 years ago

Alright. Thanks. I'll try at my end too.