Embedding wiki pages to external app using API

Hi!

I’m trying to embed wiki pages to my app.

From my server before rendering view I’m using rest/api/content/ with expand: 'body.styled_view'. Then I interpolate the result ['body']['styled_view']['value'] to my page.

Some styles don’t work properly because in exported data there is a mix of CSS, LESS (https://jira.atlassian.com/browse/CONFCLOUD-57168) and some undefined variables. So when I use it like plain CSS I don’t have styles that I need. When I try to compile it with less.js there are errors because of some imports and missed variables.

If I export pages with export_view there are no styles.

Is there a way to export pages with only styles that are needed for showing the page?

Can you remove the styles out of the exported data before showing and then only use the styles in your app. This gives you all the control.

It’s not the answer I wanted to hear :slight_smile:

I decided to pull view without styles (export_view) and add styles by myself. Yeah, it’s full control but much more work to do that already is done by Conf cloud (adding styles).