Skip to content

Commit

Permalink
fix: merge attributes without tag and attributes with tag
Browse files Browse the repository at this point in the history
  • Loading branch information
scottohara committed Oct 30, 2021
1 parent 03a81db commit 7536bfc
Show file tree
Hide file tree
Showing 3 changed files with 545 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/plugins/sources-plugin.js
Expand Up @@ -41,9 +41,10 @@ export default (options) =>

name = attribute.prefix ? `${attribute.prefix}:${name}` : name;

const handlers =
options.sources.list.get(tagName.toLowerCase()) ||
options.sources.list.get("*");
const handlers = new Map([
...(options.sources.list.get("*") || new Map()),
...(options.sources.list.get(tagName.toLowerCase()) || new Map()),
]);

if (!handlers) {
return;
Expand Down

0 comments on commit 7536bfc

Please sign in to comment.