-
Notifications
You must be signed in to change notification settings - Fork 2
Description
A user told me that they have a home-rolled pastebin that they use that doesn't get embedded. While we can't expect to support every little bin, I think the situation as it exists could be somewhat improved.
The fallback in basic for generic pastetbins uses oddly-specific selectors, which I'm assuming conform to some specific paste sites. Notably the fact that it uses direct descendent selectors body > pre and body > div > pre is somewhat limiting. However in the specific case I'm looking at it wouldn't be insurmountable.
The site would work with a selector body > div > pre > code. That selector is again rather specific, it would be odd to require a div tag like that, it could be body pre > code to be a bit more accepting, though it would have to be attempted before body > div > pre or it would never get there. Alternatively it could optionally look for a code tag inside the resulting selector and walk into it if present. Or it could use all_text rather than text to get the tag contents. Are any of these suggestions acceptable?