You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have get svg string from my server, but can not loadFromString . At the beginning, it was successful, but then suddenly it turned into a blank screen. Is that the method I used wrong?
The text was updated successfully, but these errors were encountered:
I suggest to check the console for any error message.
You can also add the alert flag to the loadfromString which will display a console message in case of exception.
The code from Editor.js:
/**
* @function module:SVGthis.loadFromString
* @param {string} str The SVG string to load
* @param {PlainObject} [opts={}]
* @param {boolean} [opts.noAlert=false] Option to avoid alert to user and instead get rejected promise
* @returns {Promise<void>}
*/
loadFromString (str, { noAlert } = {}) {
return this.ready(async () => {
try {
await this.loadSvgString(str, { noAlert })
} catch (err) {
if (noAlert) {
throw err
}
}
})
}`
set debugger:
I have get svg string from my server, but can not loadFromString . At the beginning, it was successful, but then suddenly it turned into a blank screen. Is that the method I used wrong?
The text was updated successfully, but these errors were encountered: