Rendering WebComponents in MediaWiki #253
Replies: 7 comments
-
Hi, you can simply use the Argdown app instance of @argdown/core as a starting point. That way you will automatically keep up to date if I add new plugins to some of the default processes. At the moment it is not easy to bundle @argdown/core (if you are planning to do so) because of its use of viz.js. I am currently working on that and hope to provide a simple webpack 5 example for anyone who wants to integrate Argdown into another web app. |
Beta Was this translation helpful? Give feedback.
-
Or if you run it on node you can use the Argdown app of |
Beta Was this translation helpful? Give feedback.
-
I figured out why I'm testing my plugin with my team. Once we're sure it works, we'll release it for other MediaWiki users. I am still seeing the |
Beta Was this translation helpful? Give feedback.
-
I resolved |
Beta Was this translation helpful? Give feedback.
-
Hi @DawnPaladin, The error message you get is thrown because you are loading the
You then have to take care of loading these files yourself in your html document. It would probably be best if |
Beta Was this translation helpful? Give feedback.
-
Thanks for your hard work on Argdown!! Trying to get MediaWiki to load the library exactly once is complicated. I'm putting it on my todo list. |
Beta Was this translation helpful? Give feedback.
-
I've published the MediaWiki extension for others to use! |
Beta Was this translation helpful? Give feedback.
-
Hello! I work for a nonprofit that studies ancient Hebrew literature. We use Argdown to map and analyze arguments about interpreting the Psalms. We think Argdown's text-based nature will pair really well with MediaWiki's revision control features, so I'm building a plugin that will render Argdown on MediaWiki pages.
I have a version of the plugin that successfully renders Argdown as HTML. Here's the relevant JavaScript that's running on the server:
This works! Arguments are formatted by Argdown into pretty HTML. Now I'm trying to get argument maps to work. Here's what I'm trying:
When I do that, here's what I get:
The argument being passed into Argdown is:
My console says:
There are no errors in the Network tab. I do get a couple of warnings about source maps - MediaWiki isn't delivering the source maps properly to the front end, so I'm not able to inspect deeper into symbol.ts. However, poking around in the Debugger tab shows the full path for the file that's erroring out:
https://cdn.jsdelivr.net/npm/@webcomponents/webcomponentsjs/[synthetic:es6/symbol]
That can't be right. File names shouldn't have square brackets in them. Any idea what's going on? How can I help resolve this issue?
Beta Was this translation helpful? Give feedback.
All reactions