Gathering detailed insights and metrics for @buschtoens/sparkles-component
Gathering detailed insights and metrics for @buschtoens/sparkles-component
Gathering detailed insights and metrics for @buschtoens/sparkles-component
Gathering detailed insights and metrics for @buschtoens/sparkles-component
npm install @buschtoens/sparkles-component
Typescript
Module System
Min. Node Version
Node Version
NPM Version
JavaScript (76.61%)
TypeScript (19.35%)
HTML (4.04%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
43 Stars
90 Commits
16 Forks
6 Watchers
2 Branches
10 Contributors
Updated on Feb 10, 2024
Latest Version
1.3.0-beta.1
Package Id
@buschtoens/sparkles-component@1.3.0-beta.1
Unpacked Size
409.03 kB
Size
136.14 kB
File Count
33
NPM Version
6.5.0
Node Version
11.6.0
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
10
39
Addon used to experiment with @glimmer/component
style APIs in Ember apps via
existing public APIs.
ember install sparkles-component
The sparkles-component
API supports most of the @glimmer/component
API, including:
constructor
- will be called when the component is needed, passed the evaluated named arguments for the componentdidInsertElement
- will be called after the component has been rendered the first time, after the whole top-down rendering process is completeddidUpdate
- will be called after the component has been updated, after the whole top-down rendering process is completeddestroy
- will be called when the component is no longer neededember install -S @ember-decorators/babel-transforms@^2.0.0
)experimentalDecorators
compiler option in tsconfig.json
)Missing features from @glimmer/component
:
this.bounds
within the component. At the moment there is no access available at all to the rendered DOM. The easiest work around for now would be to use an attribute in your template along with document.querySelector
.this.debugName
within the component. This was largely only present for debugging purposes, but is not possible to access in the Ember APIs at the moment.Comprehensive example (nearly exactly the same as the the glimmer.js guides):
1// app/components/conference-speakers.js (.ts would also work) 2import Component, { tracked } from "sparkles-component"; 3 4export default class ConferenceSpeakers extends Component { 5 @tracked current = 0; 6 speakers = ['Tom', 'Yehuda', 'Ed']; 7 8 @tracked('current') 9 get currentlySpeaking() { 10 return this.speakers[this.current]; 11 } 12 13 @tracked('current') 14 get moreSpeakers() { 15 return (this.speakers.length - 1) > this.current; 16 } 17 18 next() { 19 this.current = this.current + 1; 20 } 21}
1{{!-- app/templates/components/conference-speakers.hbs --}} 2 3<div> 4 <p>Speaking: {{this.currentlySpeaking}}</p> 5 <ul> 6 {{#each this.speakers key="@index" as |speaker|}} 7 <li>{{speaker}}</li> 8 {{/each}} 9 </ul> 10 11 {{#if this.moreSpeakers}} 12 <button onclick={{action this.next}}>Next</button> 13 {{else}} 14 <p>All finished!</p> 15 {{/if}} 16</div>
git clone <repository-url>
cd sparkles-component
yarn install
yarn lint:js
yarn lint:js --fix
ember test
– Runs the test suite on the current Ember versionember test --server
– Runs the test suite in "watch mode"ember try:each
– Runs the test suite against multiple Ember versionsember serve
For more information on using ember-cli, visit https://ember-cli.com/.
This project is licensed under the MIT License.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 4/7 approved changesets -- score normalized to 5
Reason
project is archived
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
110 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-07-07
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More