Skip to content

Commit

Permalink
chore(mediawiki): move imported stream parsers to token.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
bhsd-harry authored Oct 5, 2024
1 parent 2aa14f0 commit 8567be4
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions src/mediawiki.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ import {
} from '@codemirror/language';
import {MediaWiki} from './token';
import {htmlTags, tokens, htmlAttrs, elementAttrs, extAttrs} from './config';
import * as plugins from './plugins';
import {findRef} from './ref';
import type {EditorView} from '@codemirror/view';
import type {StreamParser, TagStyle} from '@codemirror/language';
Expand Down Expand Up @@ -393,14 +392,6 @@ export class FullMediaWiki extends MediaWiki {
}
}

for (const [language, parser] of Object.entries(plugins)) {
if (language === 'css' || language === 'javascript') {
Object.defineProperty(FullMediaWiki.prototype, language, {
value: (): StreamParser<object> => parser as StreamParser<object>,
});
}
}

/**
* Gets a LanguageSupport instance for the MediaWiki mode.
* @param config Configuration for the MediaWiki mode
Expand Down

0 comments on commit 8567be4

Please sign in to comment.