We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1ade945 commit 5d33f24Copy full SHA for 5d33f24
1 file changed
packages/engine-twig-php/lib/engine_twig_php.js
@@ -135,7 +135,14 @@ const engine_twig_php = {
135
// %}
136
findPartials: function(pattern) {
137
const matches = pattern.template.match(this.findPartialsRE);
138
- return matches;
+ const filteredMatches =
139
+ matches &&
140
+ matches.filter(match => {
141
+ // Filter out programmatically created includes.
142
+ // i.e. {% include '@namespace/icons/assets/' ~ name ~ '.svg' %}
143
+ return match.indexOf('~') === -1;
144
+ });
145
+ return filteredMatches;
146
},
147
148
findPartialsWithStyleModifiers(pattern) {
0 commit comments