Service is an Ember object which can be made available in the different parts of the application.
Services can be used in different kinds of areas β
- Geolocation
- Third-party APIs
- Events or notifications sent by server
- User or session authentication
- Logging
- WebSockets
You can create the service by using the following command β
ember generate service service-name
When you run the above command, it will display the following code format β
import Ember from 'ember'; //services must extend the Ember.Service base class export default Ember.Service.extend ({ });
For more about services along with an example, see this link.
Previous Page:-Click Here
Pingback: η·δΈε¨ζ¨εζ¨θ¦