Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
330 views
in Technique[技术] by (71.8m points)

jquery - Knockout- Uncaught SyntaxError: Unable to process binding "template: function() {return somedata} Message: Unexpected token ')'

I am upgrading knockout to 3.5.1.js and jquery to 3.5.1.js but getting the below issue when I click on save functionality. Below is the error I am getting

Uncaught SyntaxError: Unable to process binding "template: function(){return {name:"sectionTemplate",foreach:sections,templateOptions:{ deleteSection:deleteSection,openAddDocumentsDialog:openAddDocumentsDialog}} }"
Message: Unexpected token ')'
    at new Function (<anonymous>)
    at o (jquery.tmpl.min.js?v=-5276645587873440439:10)
    at Function.template (jquery.tmpl.min.js?v=-5276645587873440439:10)
    at a.$a.renderTemplateSource (knockout-3.5.1.js:138)
    at a.$a.a.ca.renderTemplate (knockout-3.5.1.js:119)
    at e (knockout-3.5.1.js:125)
    at u (knockout-3.5.1.js:128)
    at a.$.l (knockout-3.5.1.js:133)
    at Function.yd (knockout-3.5.1.js:55)
    at Function.zd (knockout-3.5.1.js:55)

Below is my code giving an error

 <div class="pe-sections" data-bind='template: {name: "sectionTemplate", foreach: sections, templateOptions: { deleteSection: deleteSection, openAddDocumentsDialog: openAddDocumentsDialog  } }, 
    sectionSortable: sections'>
     </div>

Please suggest to me if there any syntax changes I need to do? I tried on google but my bad not getting an exact solution.

question from:https://stackoverflow.com/questions/66064402/knockout-uncaught-syntaxerror-unable-to-process-binding-template-function

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...