News for hackers. Stuff that matters.
Re:Building OS X Apps with JavaScript by FreakyT on Sunday September 28, 2014 @09:01AM (#8379612)
What I wonder is: can this style of development be used with Interface Builder?
Re:Building OS X Apps with JavaScript by thegaw on Sunday September 28, 2014 @11:09AM (#8379904)
Yes, you can! Which is totally cool. There is a sample app written in JS that uses Xcode. They have it set up with a main.js file, they use the same ObjC.registerSubclass to create an AppDelegate. Then they have .xib for the interface. You can make the same connections from IB to the JS as you're used to.

If you have an Apple Developer account, you can download the sample project here https://developer.apple.com/wwdc/resources/sample-code It's listed under "JavaScript for Automation Cocoa Application"

Re:Building OS X Apps with JavaScript by fatboy on Sunday September 28, 2014 @10:08AM (#8379748)
It's been possible to develop AppleScript-ObjC applications using Xcode and Interface Builder for several years. I think you define properties in the AS code that Interface Builder recognises as IBOutlets to allow you to connect it all up, so I'd expect there to be a similar thing set up for the new JS stuff.
Re:Building OS X Apps with JavaScript by sjtrny on Sunday September 28, 2014 @09:29AM (#8379669)
Why would you want that? You can programmatically defibe your interface with Swift/objective-C. JavaScript feels like a step backwards to me.
Re:Building OS X Apps with JavaScript by Alphasite_ on Sunday September 28, 2014 @11:29AM (#8379959)
Because defining constraints in code is more of a faff than just doing it visually? Its also more immediate since (as far as I know) Xcode doesn't support anyform for edit and continue outside of Playgrounds.