geovistory / design-system

MIT License
2 stars 1 forks source link

Code snippet no longer works since the merge #83

Closed perrauda closed 1 year ago

perrauda commented 1 year ago

Concerning the package-optimization branch https://github.com/geovistory/design-system/pull/70

Since the merge, the code snippet no longer works.

Example: image

Commit: https://github.com/geovistory/design-system/commit/fe87cebdb91b38d5478c757f1a78ce321d7c6df7

The changes in tsxToHTML.ts may be the cause, returnvalue remains undefined because format(...) is asynchronous and returns the value too late.

let returnvalue: string;
  format(htmlString, { plugins: [pluginXML], parser: 'xml', singleQuote: true, singleAttributePerLine: true }).then(v => {
    returnvalue = v.replace(/&frasl;/g, '/').replace(/&lt;/g, '<');
  });
  return returnvalue;
flicksolutions commented 1 year ago

@perrauda should be solved...

by the way - general remark about our workflow: I misunderstood you, when you told be about the bug. #70 wasn't yet merged into main! Therefore no new issue should've been raised but you could've directly review #70 and tell me about the bug right there. This would've been a better aproach I think.

perrauda commented 1 year ago

@flicksolutions @joschne this issue is solved, isn't it?

flicksolutions commented 1 year ago

Yes, definitely! Thanks for the heads up!