Skip to content
This repository has been archived by the owner on May 19, 2023. It is now read-only.

Commit

Permalink
fix(for): nested for loops
Browse files Browse the repository at this point in the history
  • Loading branch information
aidenybai committed Mar 4, 2021
1 parent 501e17f commit 6f9b47a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/core/directives/for.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { DIRECTIVE_PREFIX } from '../../models/generics';
import { DirectiveProps } from '../../models/structs';

import compile from '../../core/compile';
Expand Down Expand Up @@ -63,6 +64,7 @@ export const forDirective = ({ el, data, state, node }: DirectiveProps) => {

if (!marker) {
adjustDeps(ast, data.deps, node, 'for');
el.removeAttribute(`${DIRECTIVE_PREFIX}for`);
}

render(compile(el, state), directives, state, node.deps);
Expand Down

0 comments on commit 6f9b47a

Please # to comment.