Skip to content

Commit

Permalink
Merge pull request #793 from lblod/GN-5245-modernize-templates
Browse files Browse the repository at this point in the history
GN-5245: apply new template instantiate method on built-in standard templates
  • Loading branch information
elpoelma authored Dec 13, 2024
2 parents 3ad947f + c46adbc commit b6806d9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/strong-rats-shave.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'frontend-gelinkt-notuleren': patch
---

Apply new `instantiateUuids` method onto built-in standard templates
3 changes: 2 additions & 1 deletion app/components/document-creator.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,8 @@ export default class DocumentCreatorComponent extends Component {
return templateUuidInstantiator(trimmedHtml);
} else {
const trimmedHtml = this.template.body.replace(/>\s+</g, '><');
return instantiateUuids(trimmedHtml);
// If it's a built=in template, we apply both instantiate functions
return instantiateUuids(templateUuidInstantiator(trimmedHtml));
}
} else return '';
}
Expand Down

0 comments on commit b6806d9

Please sign in to comment.