![Malicious npm Package Typosquats react-login-page to Deploy Keylogger](https://cdn.sanity.io/images/cgdhsj6q/production/007b21d9cf9e03ae0bb3f577d1bd59b9d715645a-1024x1024.webp?w=400&fit=max&auto=format)
Research
Security News
Malicious npm Package Typosquats react-login-page to Deploy Keylogger
Socket researchers unpack a typosquatting package with malicious code that logs keystrokes and exfiltrates sensitive data to a remote server.
@ember-data/model
Advanced tools
Readme
Runtime Classes for use as a Schema Source and Resource Presentation for EmberData
Install using your javascript package manager of choice. For instance with pnpm
pnpm add @ember-data/model
Tagged Releases
Provides a Presentation Model for resource data in an EmberData Cache
This package implements the EmberData Store's instantiateRecord
and teardownRecord
hooks
as well as configures an associated SchemaService
implementation.
Models are defined as classes extending from import Model from '@ember-data/model';
and the
attributes and relationships on these classes are parsed at runtime to supply static "schema"
to EmberData's SchemaService.
Resource data for individual resources fetched from your API is presented to the UI via instances
of the Model
s you define. An instantiated Model
is referred to as a record
.
When we refer to the ModelClass
as opposed to a Model
or Record
we are referring
specifically to the class definition and the static schema methods present on it.
When we refer to a record
we refer to a specific class instance presenting
the resource data for a given type
and id
.
app/models/person.js
import Model, { attr, belongsTo, hasMany } from '@ember-data/model';
export default class PersonModel extends Model {
@attr name;
@belongsTo('pet', { inverse: 'owners', async: false }) dog;
@hasMany('person', { inverse: 'friends', async: true }) friends;
}
By convention, the name of a given model (its type
) matches the name
of the file in the app/models
folder and should be lowercase, singular
and dasherized.
FAQs
Unknown package
We found that @ember-data/model demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers unpack a typosquatting package with malicious code that logs keystrokes and exfiltrates sensitive data to a remote server.
Security News
The JavaScript community has launched the e18e initiative to improve ecosystem performance by cleaning up dependency trees, speeding up critical parts of the ecosystem, and documenting lighter alternatives to established tools.
Product
Socket now supports four distinct alert actions instead of the previous two, and alert triaging allows users to override the actions taken for all individual alerts.