Hi everyone, the next version of the Mobile SDK, version 47.0, will include a few changes that may require you to update your code. This release should become available within a couple of weeks; we wanted to give you advance notice on this so you can prepare if needed.
Summary of the Changes
Syntax Changes
Functionality
|
Old Syntax
|
New Syntax
|
Get Orientation
|
nomad.getOrientation() |
app.nomad.screen.orientation Note: Possible values are
app.Orientation.LANDSCAPE or app.Orientation.PORTRAIT |
Narrow Tablet Mode
|
app.isNarrowTabletMode |
N/A - the property is deprecated
|
Webpack Alias Changes
Previous list of available webpack aliases
jquery: 'zepto/src/zepto',
'%vendor%': path.resolve(__dirname, '../node_modules'),
'%seedbed%': path.resolve(__dirname, '../', 'seedbed'),
'%Seedbed%': path.resolve(__dirname, '../', 'Seedbed'),
'%cukes%': path.resolve(__dirname, '../', 'cukes'),
'%app%': path.resolve(__dirname),
'%app.js%': '%app%/js',
'%app.lib%': '%app%/lib',
'%sidecar%': `%app.lib%/sidecar/sidecar`,
'%app.core%': '%app.js%/core',
'%app.offline%': '%app.js%/offline',
'%app.layouts%': '%app.js%/layouts',
'%app.views%': '%app.js%/views',
'%app.views.list%': '%app.views%/list',
'%app.views.detail%': '%app.views%/detail',
'%app.views.edit%': '%app.views%/edit',
'%app.plugins%': '%app.js%/plugins',
'%app.fields%': '%app.js%/fields',
'%app.dashlets%': '%app.js%/dashlets',
'%app.navigation%': '%app.core%/navigation',
'%app-config%': path.dirname(appConfigOverridesPath),
'%app-dev-config%': `%app%/config${isDebug ? '-dev' : ''}.json`,
'%tests%': path.resolve(__dirname, 'tests'),
'%nomad-specs%': '%tests%/specs',
'%platform-scripts%': path.resolve(__dirname, 'entries', `scripts-${PLATFORM === 'web' ? 'web' : 'native'}.js`)
New list of available webpack aliases
jquery: 'zepto/src/zepto',
'%vendor%': path.resolve(__dirname, '../node_modules'),
'%seedbed%': path.resolve(__dirname, '../', 'seedbed'),
'%Seedbed%': path.resolve(__dirname, '../', 'Seedbed'),
'%cukes%': path.resolve(__dirname, '../', 'cukes'),
APP: path.resolve(__dirname),
OFFLINE: 'APP/js/offline',
VIEWS: 'APP/js/views',
FIELDS: 'APP/js/fields',
UTILS: 'APP/js/utils',
'%app-config%': path.dirname(appConfigOverridesPath),
'%app-dev-config%': `APP/config${isDebug ? '-dev' : ''}.json`,
'%platform-scripts%': path.resolve(__dirname, 'entries', `scripts-${PLATFORM === 'web' ? 'web' : 'native'}.js`)
Stay tuned for the version 47.0 release notes once the version is available! Also check out the Mobile SDK Developer Guide for details on working with the SDK, including code examples. The guide will be updated to reflect the changes once the new version of the SDK is available for download.