Хотите пройти тесты на Upwork на хороший результат?
Подавайте заявку и мы поможем Вам это сделать!

Do You want to pass tests on Upwork with good scores?
Leave the request and we will help You to do that!

Ionic Framework Test 2018

Мы не гарантируем правильность всех предоставленных ответов.


75 Test Questions:

1. What can be called after the current play/record or stop action has completed?

Answers:

• mediaSuccess
• mediaComplete
• mediaStatus
• All of the above

2. Which cordova plugin is used to open external links form your app inside a web browser view?

Answers:

• org.apache.cordova.browser
• org.apache.cordova.inappbrowser
• org.apache.native.inappbrowser
• org.apache.cordova.lonicbrowser

3. Which of the following SASS files is the «main» style file in Ionic 2 project?

Answers:

• style.scss
• main.scss
• global.scss
• app.scss

4. Which command(s) can you use to start an an app from scratch?

Answers:

• ionic start myApp blank
• ionic start myApp tabs
• ionic start myApp sidemenu
• All of the above

5. Which of the following statement is True for a command line utility?

Answers:

• A command line utility is one to be used from a shell (or commonly known as a Terminal). It receives input from this shell, and reports its output in the same shell.
• A command line utility is one to be used from a cli (or commonly known as a Terminal). It receives input from this cli, and reports its output in the same cli.
• A command line utility is one to be used from a cordova (or commonly known as a Terminal). It receives input from this cordova, and reports its output in the same cordova.
• None of the above

6. Ionic ____ system is that it is FlexBox?

Answers:

• Grid
• CSS
• Layout
• Module

7. Which of the following commands can be used to create a component with preview-box selector?

Answers:

• ionic PreviewBox component -g
• ionic -g component PreviewBox
• ionic -g component preview-box
• ionic -g PreviewBox component

8. How can tap for a div and all of its children elements disabled?

Answers:

• <div data-tap-disabled=“true”> … </div>
• <div data-tap=“disable”> … </div>
• <div tap=“disable”> … </div>
• <div tap-disabled=“true”> … </div>

9. Which of the following properties can be passed while creating marker?

Answers:

• lat
• snippet
• lng
• All of the above

10. Which of the following Google Maps instances are exists in ionic-native after installing google-maps package ?

Note: There may be more than one right answer.

Answers:

• GoogleMapsLatLng
• GoogleMap
• GoogleMapsEvent
• All of the above

11. Use input-label to place a label to the left of the input element. When the user enters text the label does not hide. Note that there’s nothing stopping you from also using a placeholder label too?

Answers:

• <div class=»list»>
<label class=»item item-input»>
<input type=»text» placeholder=»First Name»>
</label>
<label class=»item item-input»>
<input type=»text» placeholder=»Last Name»>
</label>
<label class=»item item-input»>
<textarea placeholder=»Comments»></textarea>
</label>
</div>
• <div class=»list»>
<label class=»item item-input»>
<span class=»input-label»>Username</span>
<input type=»text»>
</label>
<label class=»item item-input»>
<span class=»input-label»>Password</span>
<input type=»password»>
</label>
</div>
• Both of the above
• None of the above

12. Ionic is a open source, front-end?

Answers:

• SDK
• Tool
• Framework
• Language

13. How to set ion-select component with 100% width in IONIC 2?

Answers:

• .myCustomSelect{ width: 100% !important; }
• .myCustomSelect{ component-width: 100% !important; }
• .myCustomSelect{ max-width: 100% !important;}
• All of the above

14. Which of the following is correct explanation of abbreviature FAB?

Answers:

• Flexbox Active Bar
• Front Action Block
• Floating Action Buttons
• Feature Attribute Buttons

15. Range will usually require icons to display data clearly. We just need to add icons before and after range input to place them on both sides of the range element choose a correct answer?

Answers:

• <div class = «list»>
<div class = «item range range-light»>
<input type = «range» name = «volume»>
</div>
</div>
• <div class = «item range»>
<input type = «range» name = «range1»>
</div>
• <div class = «item range»>
<i class = «icon ion-volume-low»></i>
<input type = «range» name = «volume»>
<i class = «icon ion-volume-high»></i>
</div>
• All of the above

16. All Ionic color classes can be applied to toggle element?

Answers:

• Multiple Toggles
• Styling Toggle
• Toggle
• All of the above

17. Which code below will add a custom page transition on Ionic 2?

Answers:

• import { Config } from ‘ionic-angular’;
@NgModule({})
class AppModule {
constructor(private config: Config) {
this.config.setTransition(‘fade-transition’, FadeTransition);
}
}
• import { Component} from ‘@angular/core’;
import { NavController, Slides} from ‘ionic-angular’;
@Component({
constructor(private config: Config) {
this.config.setTransition(‘fade-transition’, FadeTransition);
})
• import { NavController, Slides} from ‘ionic-angular’;
@Component({
constructor(private config: Config) {
this.config.setTransition(‘fade-transition’, FadeTransition);
})
• All of the above

18. Ionic provides custom ___ and methods?

Answers:

• Classes
• Methods
• Components
• Controller

19. Using the following code, How can you call node server using ionic?

Answers:

• angular.module(‘starter.services’, [‘ngResource’])
.factory(‘Session’, function ($resource) {
return $resource(‘httр://XXX.XXX.XXX.XXX:5000/sessions/:sessionId’);
});
• var express = require(‘express’);
var app = express();
app.get(‘/’, function (req, res) {
res.send(‘Hello World!’);
});
app.listen(3000, function () {
console.log(‘Example app listening on port 3000!’);
});
• angular.module(‘starter.services’, [‘ngResource’])
.factory(‘Session’, function ($resource) {
return $resource{(‘httр://XXX.XXX.XXX.XXX:5000/sessions/’)};
});
• Both of the above

20. Ionic Framework has the following Features?

Note: There may be more than one right answer.

Answers:

• AngularJS
• CSS components
• Ionic CLI
• Blaze

21. How i can get the input value within ionic 2 in my Component as following?

Answers:

• <ion-header>
<ion-navbar primary>
</ion-navbar>
</ion-header>
<ion-content>
<ion-item>
<button lightgray full (click)=»incrementQty()»>+</button>
<ion-item>
<ion-input type=»number» min=»1″ [value]=»qty» [(ngModel)]=»qty»></ion-input>
</ion-item>
<button lightgray full (click)=»decrementQty()»>-</button>
</ion-item>
</ion-content>
• import { Component} from ‘@angular/core’;
import { NavController, Slides} from ‘ionic-angular’;
@Component({
templateUrl: ‘build/pages/titlepage/titlepage.html’,
})
export class titlePage {
qty:any;
constructor({private nav: NavController)} {
this.qty = 1;
}
// increment product qty
incrementQty() {
console.log(this.qty+1);
this.qty += 1;
}
// decrement product qty
decrementQty() {
if(this.qty-1 < 1 ){
this.qty = 1
console.log(‘1->’+this.qty);
}else{
this.qty -= 1;
console.log(‘2->’+this.qty);
}
}
• Both of the above
• import { Component} from ‘@angular/core’;
import { NavController, Slides} from ‘ionic-angular’;
@Component({
templateUrl: ‘build/pages/titlepage/titlepage.html’,
})
export class titlePage {
qty:any;
constructor(private nav: NavController) {
this.qty = 1;
}
// increment product qty
incrementQty() {
console.log(this.qty+1);
this.qty += 1;
}
// decrement product qty
decrementQty() {
if(this.qty-1 < 1 ){
this.qty = 1
console.log(‘1->’+this.qty);
}else{
this.qty -= 1;
console.log(‘2->’+this.qty);
}
}
}

22. Remove pager (dots) in new ion-slides ionic component?

Answers:

• options=»{pagination: false}»
• options=»{pagination: true}»
• <ion-slide-box show-pager=»true»>
• <ion-slide-box pager=»false»>

23. Assume use the following code int the controller , Which of the following prints the value of the myVar in each click to the checkbox?

$scope.myVar = false;
$scope.clickMe = function(){
console.log(myVar)
};

Answers:

• <ion-checkbox ion-model=»myVar» ion-change=“clickMe()”></ion-checkbox>
• <ion-checkbox ng-model=»myVar» ng-change=»clickMe()»></ion-checkbox>
• <ion-checkbox ng-model=»myVar» ion-change=“clickMe()”></ion-checkbox>
• <ionic-checkbox ionic-model=»myVar» ionic-change=“clickMe()”></ion-checkbox>

24. Which of the following components is not exist in Ionic 2?

Answers:

• Checkbox
• Tooltip
• Slides
• Toast

25. Plugins are where Cordova stores the plugins that you add to your project. Plugins are added by the following command?

Answers:

• ionic plugin add {plugin}
• ionic plugin install {plugin}
• ionic plugin add (plugin)
• ionic install plugin

26. What is the Ionic Framework Features as following?

Answers:

• AngularJS, CSS components
• JavaScript components, Cordova Plugins
• Ionic CLI, Ionic View
• Licence
• All of the above

27. Which of the following are Ionic Events? Check all that apply.

Note: There may be more than one right answer.

Answers:

• on-hold
• on-touch
• on-hide
• on-swipe

28. Which of the following properties can be passed to create method of Toast component?

Note: There may be more than one right answer.

Answers:

• duration
• position
• class
• All of these.

29. The _____ repository contains all of the AngularJS wrappers for Cordova plugins to make it easier for you to use the plugins?

Answers:

• ngCordova
• Ionic View
• Ionic CLI
• None of the above

30. Returns: promise A promise which is resolved when the modal is finished animating in?

Answers:

• remove()
• hide()
• isShown()
• show()

31. Ionic has __ that are purely CSS-driven?

Answers:

• modal
• components
• controller
• template

32. Which of the following are CSS components of Ionic?

Note: There may be more than one right answer.

Answers:

• Colors
• Checkbox
• Backdrop
• All of the above

33. Which directive is used to attach a controller to the DOM?

Answers:

• ionic-controller
• ion-controller
• ionic-controller
• ng-controller

34. Ionic provides many services like __ and various delegate services?

Answers:

• $loading, $actionSheet
• $loading, $actionSheet
• $loading, $state
• $scope, $actionSheet

35. How to hide some elements when keyboard open?

Answers:

• By using hide-on-keyboard-open class in elements
• By using hide-element-on-keyboard-open
• By using hide-on-keyboard-open view in elements
• None of the above

36. Which option is used for making a choice or editing an item by temporarily going over the user’s main view?

Answers:

• Modal
• View
• Controller
• Model

37. Which of the following components allows you to see the next page in navigation stack?

Answers:

• naxNext
• navPop
• navPush
• locationPath

38. Which of the following are True regarding Ionic Framework?

Note: There may be more than one right answer.

Answers:

• Ionic is open source
• Ionic is used for developing mobile application
• It provides tools and services for building mobile UI with native look and feel
• None of the above

39. Which of the following attribute needed to define for ionic application?

Answers:

• ng-app
• ion-module
• ionic-app
• ion-app

40. Which of the following components needed to start with Ionic?

Note: There may be more than one right answer.

Answers:

• NodeJS
• Android SDK
• XCode
• Cordova and Ionic
• MeteroJS

41. Which of the following controllers is responsive for navigating in Ionic 2?

Answers:

• StateController
• NavigationController
• NavController
• RouteController

42. In AppCtrl controller, how can you retrieve and set the platform using ionic.Platform?

Answers:

• .controller(‘AppCtrl’, function($scope) {
$scope.platform = Platform.platform();
})
• .controller(‘AppCtrl’, function($scope) {
$scope.platform = ionic.Platform.platform();
})
• Both of the above
• .controller(‘AppCtrl’, function($scope) {
$scope.platform => ionic.platform();
})

43. Which of the following are Ionic 2 decorators?

Note: There may be more than one right answer.

Answers:

• @Pipe
• @Push
• @Page
• @Plugin

44. Which of the following Cordova plugins can be used for geolocation?

Answers:

• cordova-plugin-geolocation
• cordova-geolocation-plugin
• geolocation-plugin
• navigator.geolocation

45. Toggle can be implemented using how many Ionic classes?

Answers:

• one
• two
• three
• four

46. Which of the following life cycle events exist in Ionic 2 navigation? Check all that apply.

Note: There may be more than one right answer.

Answers:

• ionViewDidEnter
• ionViewInitLoad
• ionViewDidLoad
• All of these.

47. Which of the following plugins exists in Ionic Native? Check all that apply.

Note: There may be more than one right answer.

Answers:

• Camera
• Charger
• Bluetooth Status
• All of the above

48. Which of the following is the correct way to pass data between Controller/View in Ionic?

Answers:

• .controller(‘SearchResultsCtrl’, function($scope, $state, $stateParams) {

$scope.results = $stateParams.result;

});
• .controller(‘SearchCtrl’, function($scope, $state, $http) {
alert(«Search OK»);
//take the data.results and make sure its availab
$scope.search = function() {
console.log(‘Starting search..’);
var res = $http.post(‘httр://endpoint:8080/search’,{«language»:»en»})
.success(function(data) {le when I move to tab.search-results
$state.go(‘tabs.search-results’, {result: data});
}).error(function(data) {
alert(«Search Bad»);
});
};
})
• .controller(‘SearchCtrl’, function($scope, $state, $http) {
$scope.search = function() {
console.log(‘Starting search..’);
var res = $http.post(‘httр://endpoint:8080/search’,{«language»:»en»})
.success(function(data) {
//take the data.results and make sure its available when I move to tab.search-results
alert(«Search OK»);
})
.error(function(data) {
alert(«Search Bad»);
});

//take the data.results and make sure its available when I move to tab.search-results
$state.go(‘tabs.search-results’);
};
})
• All of the above

49. Which of the following SASS variables exist in Ionic 2?

Answers:

• $action-sheet-wp-title-text-align
• $action-sheet-ios-text-align
• $action-sheet-ios-border-radius
• All of the above

50. Which of the following statements are true about Ionic-nav-view? (choose all that apply)

Note: There may be more than one right answer.

Answers:

• used for navigation
• should be placed in index.html
• none of the above
• should be placed inside app folder

51. What are the methods of the ionic.EventController?

Answers:

• on, of, trigger, onGesture, ofGesture
• on, of, trigger
• subscribe, unsubscribe, trigger
• add, remove, trigger

52. How do you persist data between application launches? Check all that apply.

Note: There may be more than one right answer.

Answers:

• localStorage
• sessionStorage
• webStorage
• appStorage

53. Which of the following methods will display location on the map with special zoom level?

Answers:

• getLocation
• animateMap
• zoomCamera
• animateCamera

54. Ionic provides all ten of the animated _____ within 3KB.

Answers:

• SVGs
• Gif
• Banner
• SWF

55. Using the following code, how can you disable cache with an attribute?

Answers:

• <ion-view cache-view=»false» view-title=»My Title!»>

</ion-view>
• <ion-view cache-view=»true» view-title=»My Title!»>

</ion-view>
• Both of the above
• None of the above

56. Which of following options are true regarding native audio? Check all that apply.

Note: There may be more than one right answer.

Answers:

• preloadSimple is used for simple sounds that will be played once
• preloadComplex for sounds that will be played as looping sounds or background audio
• preloadSimple is used for background audio
• All of the above

57. Which of the following disables caching the views in Ionic apps?

Answers:

• $ionicConfigProvider.views.maxCache(0);
• $ionicConfigProvider.views.setCache(0);
• $ionicConfigProvider.disableViews();
• $ionicConfigProvider.setViews(false);

58. Which of the following params should be passed first while creating new Map instance ?

Answers:

• Class of element
• DOM element
• ID of element
• All of the above

59. Which of the following $colors exists in Ionic 2? Check all that apply.

Note: There may be more than one right answer.

Answers:

• primary
• secondary
• priority
• All of the above

60. Which service is used for navigation in Ionic?

Answers:

• $navigationProvider
• $ionicHistory
• Both of the above
• $viewProvider

61. Which of the following lines shows the Unique Device id ?

Answers:

• console.log(Device.device.id);
• console.log(Device.device.uuid);
• console.log(Device.uuid);
• console.log(Device.device);

62. What is the impact on performance of localStorage in an Ionic app?

Answers:

• You should replace localStorage values frequently, because once you set value it will not be changed unless you change it.
• If the application goes with large data, you have to choose Sqlite.
• Avoid storing complex data in localStorage, because you should not play with code logic with the help of localStorage.
• All of the above

63. By default, Ionic will cache a maximum of …………… views.

Answers:

• 10
• 15
• 30
• 40

64. A complex popup has a buttons _____ with each button having a text.

Answers:

• Array
• String
• Label
• Property

65. Which option displays Ionic framework JSON data retrieving?

Answers:

• $http.get(‘content.js’).success(function(response) {
//whereever you want to put the data
});
• $http.get(‘content.js’).addSuccess(function(response) {
//whereever you want to put the data
});
• $http.get(‘content.js’).getSuccess(function(response) {
//whereever you want to put the data
});
• All of the above

66. Which service should be injected into controller to make http request?

Answers:

• $http
• $httpRequest
• $httpSession
• $httpConnection

67. Which one is the main class for Header & Footer?

Answers:

• header
• bar
• footer
• None of the Above

68. Which option allows you to include ngCordova plugins in an Ionic app?

Answers:

• cordova plugin add httрs://github.com/wildabeast/BarcodeScanner.git
• module.controller(‘BarcodeCtrl’, function($scope, $cordovaBarcodeScanner) {
document.addEventListener(«deviceready», function () {
$cordovaBarcodeScanner
.scan()
.then(function(barcodeData) {
// Success! Barcode data is here
}, function(error) {
// An error occurred
});
)};
• Both of the above
• module.controller(‘BarcodeCtrl’, function($scope, $cordovaBarcodeScanner) {
document.addEventListener(«deviceready», function () {
$cordovaBarcodeScanner{
.then(function(barcodeData) {
// Success! Barcode data is here
}, function(error) {
// An error occurred
});
)};

69. Which service is used for Ionic Popover?

Answers:

• $ionicPopup
• $ionicPopover
• $ionicPopup
• All of the above

70. Which of the following plugins can be used for safety storage?Answers:

• cordova-plugin-safe-storage
• cordova-plugin-secure-storage
• cordova-plugin-sqlite-storage
• cordova-plugin-sql-storage

71. For example, the NativeStorage is connected.
Which of the following lines of code correctly adds newItem to storage?

Answers:

• new NativeStorage(‘newItem’, {new: 1});
• NativeStorage.setItem(‘newItem’, {new: 1}).then(()=>);
• NativeStorage.newItem(‘newItem’, {new: 1}, cb);
• NativeStorage.set(‘newItem’, {new: 1});

72. The CLI automatically adds a new ……….. named resources.

Answers:

• Folder
• File
• Icon
• Screen

73. How you can remove caching completely in Ionic?

Answers:

• $http.get(‘content.js’).success(function(response) {
$scope.doRefresh()
});
• $http.get(‘content.js’).getSuccess(function(response) {
$scope.doRefresh()
});
• $scope.$on(‘$ionicView.beforeEnter’, function () {
$scope.doRefresh();
});
• All of the above

74. Which gesture is used for the touch that stays at the same location 500ms?

Answers:

• on-hold
• on-tap
• on-pressed
• on-touch

75. How can Ionic framework be injected into javascript?

Answers:

• angular.module(‘myApp’, [‘ionic-app’])
• angular.app(‘myApp’, [‘ionic-app’])
• angular.app(‘myApp’, [‘ionic’])
• angular.module(‘myApp’, [‘ionic’])