angularjs - Angular, ng-init doesn't initialize -



angularjs - Angular, ng-init doesn't initialize -

trying initial text box ng-init text box blank?

<form ng-app="theapp" ng-init="email='test@test.com'"> <div> <label>email: </label> &nbsp;<input type="text" ng-model="email"> </div> </form>

i don't know if you're starting angular correctly. dropping ="theapp" makes work. see fiddle.

in app.js, defining angular module theapp? i.e. angular.module('theapp', [])

<form ng-app ng-init="email = 'test@test.com'"> <div> <label>email: </label> &nbsp;<input type="text" ng-model="email"> </div> </form>

angularjs angularjs-directive

Comments

Popular posts from this blog

xslt - DocBook 5 to PDF transform failing with error: "fo:flow" is missing child elements. Required content model: marker* -

mediawiki - How do I insert tables inside infoboxes on Wikia pages? -

Local Service User Logged into Windows -