- Lightweight Editor for Windows 7+, Mac OSX, Linux - It’s free, open source. (based on Electron) • Visual Studio Code – plugin for Ext JS developers • Will be available for all Sencha tiers!
multiple files - Concatenated into a single <script> - Requiring classes may break the example • Data requests are hidden - All client side, no network requests • Not so great for full app examples • Funky UI 12
Much more like local development • Data requests are real network requests! - Inspectable in browser dev tools • Ext JS packages! * • Sencha Inspector integration • Better UI • * being populated •
to manage frameworks where you can choose to install or remove framework or Sencha Cmd versions. • You can find the Manage Frameworks option in File tab in Preferences menu.
premium components • You will need the premium license to use the components • With the license you receive the Addons.zip, you will need to extract the packages into the [MyApp]/ext/packages folder and build.
to win a great prize. Use Sencha Themer 1.1 Early Access to give our contest app a great new look. • Create a theme for a Sencha App • Top prize winner will receive $2500! https://www.sencha.com/sencha-theming-contest-2016/
require tooling. Our frameworks have to deal with legacy browsers. • Sencha will need a transpiler to compile back to old fashioned ES5 code. • Our goal is to let your ES2015 code run together with the Sencha framework code. • Cmd is Java based! With Sencha Cmd 6.5, code gets transpiled! Under the hood, we will use Google Closure Compiler. (We replaced Rhino)
use it, you owe yourself to check the output and end result • Transpilers generate code which is supported by the current browsers. It might not be the code what you would expected.
modern web capabilities to deliver an app-like user experience. They evolve from pages in browser tabs to immersive, top-level apps, maintaining the web's low friction at every moment.“
of device, OS or platform • Have rich, (native) app-like components / UIs • Have fast performance • Are secure, they run over https • Can load instantly • Can run in offline mode or with a limited network connection • Can be added to the homescreen (and have an icon and a splash screen)
service worker for you. - Writes the caching mechanism - Lists all your assets • Requires Node JS 6+ to be installed. • Setup in app.json http://docs.sencha.com/cmd/guides/progressive_web_apps.html
Ant It’s a task runner, which allows you to: • Generation of code and applications • Built-in server (Jetty server) • File watcher • Load assets (Microloader) • Compilation of Sass Themes (Fashion) • Bundling files • Compress, Optimize and Transpile files (Google Closure Compiler) • Support for Cordova, Electron, PWA’s etc… • Upgrade between versions
tree into chunks loaded on demand • Keep initial loading time low • Every static asset should be able to be a module • Ability to integrate 3rd-party libraries as modules • Ability to customize nearly every part of the module bundler • Suited for big projects
'/build', filename: 'bundle.js' }, resolve: { alias: { 'somePackage': '/path/to/my/code’ } }, module: { loaders: [{ test: /\.js$/, loader: 'babel', query: { plugins: [ 'babel-plugin-transform-es2015-modules-commonjs' ] } }] } }; Webpack Configuration • Entry point and output initialization • Alias resolution allows code to be located in locations what work for developers • Module Loaders allow for code transformation before bundling Entry & Build Basic config for entry point and location of build files entry: './app.js', output: { path: __dirname + '/build', filename: 'bundle.js' }, Resolver & Alias Powerful aliasing features allow you to keep code where you want. resolve: { alias: { 'somePackage': '/path/to/my/code’ } }, Loaders Transformations applied to a file in your application. This can be used to do anything from transpile to compress images loaders: [{ test: /\.js$/, loader: 'babel', query: { plugins: [ 'babel-plugin-transform-es2015-modules-commonjs' ] } }]
• Plugin based allows control of what code is transpiled • Polyfill for new functionality not supported in your target target browser • Source maps for debugging compiled code in the browser
by Microsoft • Slack Team Collaboration • Kitematic by Docker • Sencha • Sencha Architect • Sencha Themer • Sencha Inspector • Sencha Test Who uses Electron?
applications as native desktop apps • Open source ext-electron package by Sencha - IPC (inter process communication) to push heavy workloads to the main process - Example with easy integration, to quickly wrap applications - Support for native menu’s - Support for native GUI’s • File Pickers • Folder Pickers • Tray Icons • Notifications / “Balloons” Download from: http://github.com/sencha/electron-demo
• Uses npm scripts instead of gulp or grunt. • You can use the npm or yarn package managers. • The electron-packager wraps the compiled Ext JS application as produced by Sencha Cmd. • Application code will be stored in an “asar” file. - See http://electron.atom.io/docs/tutorial/application-packaging/
(32 or 64) - Mac OS X - Linux (x86, x86_64, and armv7l) • Applications can be built on: - Windows (32 or 64) - Mac OS X (darwin, mas) - Linux (x86 or x86_64)
app - Entry point is “app.js” in root folder - Other code is in “./app” folder • Main process logic is just Node.js code - Entry point is “main.js” in root folder - Other code is in “./main” folder
= service.heavyWork(42, result => { console.log(`Work is done: ${result}`); }); console.log(`Initial work value: ${v}`); // log: // > Initial work value: 21 // > Work is done: 427 Use remote To Off-load Work • Push heavy workloads to the main process. • Initial result is synchronously returned! • Callbacks can be used to return data asynchronously as well. • Very convenient compared to raw IPC methods. module.exports = { heavyWork (value, done) { setTimeout(() => { done(value * 10 + 7); }, 2500); return v / 2; } }; ./main/service.js ./app/...
creation is easiest with a template • Templates have no conditional pieces • API’s to maintain menu state (checked, visible, enabled) are rather new • Editing menus after creation is difficult
submenu: [{ label: 'Reopen', submenu: 'getReopenMenu' }, { label: 'Exit', accelerator: 'CmdOrCtrl+Q', click: 'onExit' }] }, ... Ext.electron.menu.Manager • Declarative, dynamic menus • Menu and menu item properties can be specified via: - Value - Inline function - Named controller method • Click handlers can be: - Inline function - Named controller method
= recentFiles.indexOf(path); if (i > -1) { recentFiles.splice(i, 1); } recentFiles.push(path); if (recentFiles.length > 3) { recentFiles.shift(); } this.getView().reloadNativeMenu('app'); } Ext.electron.menu.Manager • Call reload method when state changes to update the menu:
Visual Studio Code plugin EA • Sencha Architect 4.1 • Fiddle 2.0 • Sencha Themer 1.1 • Electron for Sencha package • Sencha Cmd 6.5 EA - Google Closure Compiler for ES2015 support - PWA / Service Worker support • Sencha Test 2.0