Skip to content

Commit

Permalink
fixed rewriting regex
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronblohowiak committed Dec 5, 2010
1 parent 000cee3 commit 2f08100
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion build/output/knockout-latest.debug.js
Expand Up @@ -1353,7 +1353,7 @@ ko.templateEngine = function () {
ko.exportSymbol('ko.templateEngine', ko.templateEngine);

ko.templateRewriting = (function () {
var memoizeBindingAttributeSyntaxRegex = /(<[a-z]+(\s+(?!data-bind=)[a-z0-9]+(=(\"[^\"]*\"|\'[^\']*\'))?)*\s+)data-bind=(["'])([\s\S]*?)\5/g;
var memoizeBindingAttributeSyntaxRegex = /(<[a-z]+\d*(\s+(?!data-bind=)[a-z0-9]+(=(\"[^\"]*\"|\'[^\']*\'))?)*\s+)data-bind=(["'])([\s\S]*?)\5/g;

return {
ensureTemplateIsRewritten: function (template, templateEngine) {
Expand Down
4 changes: 2 additions & 2 deletions build/output/knockout-latest.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/templating/templateRewriting.js
@@ -1,6 +1,6 @@

ko.templateRewriting = (function () {
var memoizeBindingAttributeSyntaxRegex = /(<[a-z]+(\s+(?!data-bind=)[a-z0-9]+(=(\"[^\"]*\"|\'[^\']*\'))?)*\s+)data-bind=(["'])([\s\S]*?)\5/g;
var memoizeBindingAttributeSyntaxRegex = /(<[a-z]+\d*(\s+(?!data-bind=)[a-z0-9]+(=(\"[^\"]*\"|\'[^\']*\'))?)*\s+)data-bind=(["'])([\s\S]*?)\5/g;

return {
ensureTemplateIsRewritten: function (template, templateEngine) {
Expand Down

0 comments on commit 2f08100

Please sign in to comment.