Issue #2518Opened January 21, 2020by denish-kanabar4 reactions

Webpage plugin: import & export code options in AngularJS application

Question

Hello Team,

I have bit different requirement for export and import code. Is it possible to get html and css in memory (i want to save it in DB ) instead of opening PopUp which gives an option to save zip file ?

I am using webpage plugin in angular app

Also is it possible to load page with pre-rendered or pre-supplied HTML while opening or loading container?

Requirement is to modify current behavior of export and import feature of webpage plugin

Answers (3)

pouyamiralayiJanuary 23, 20202 reactions

@denish-kanabar you can do this way:

editor.setComponents(
  `
     <div> Default Template! </div>
     <style> div { background: teal} </style>
  `
)

Cheers!

pouyamiralayiJanuary 21, 20201 reactions

Hi @denish-kanabar

Is it possible to get html and css in memory

editor.getHtml()
editor.getCss()

(i want to save it in DB )

please refer to the storage api

load page with pre-rendered or pre-supplied HTML

editor.setComponents('<div>Default Template!</div>')

cheers!

denish-kanabarJanuary 22, 20201 reactions

have checked that thread and from there only could import plugins but now issue is with calling API while adding command for editor to save in DB

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.