Socket
Book a DemoInstallSign in
Socket

ember-cli-pull-to-refresh

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ember-cli-pull-to-refresh

A pull-to-refresh plugin for Ember CLI apps.

0.0.15
latest
Source
npmnpm
Version published
Weekly downloads
0
-100%
Maintainers
1
Weekly downloads
 
Created
Source

Build Status npm version Code Climate Test Coverage

Ember-cli-pull-to-refresh

A simple pull-to-refresh component for wrapping Ember CLI components.

Usage

This component is meant to wrap the content being refreshed:

{{#pull-to-refresh
  refresh='refresh'
  threshold=50
  refreshing=refreshing
  scrollable='.some-selector'
  disableMouseEvents=false
}}
  {{! render your model here }}
{{/pull-to-refresh}}

When the user drags the pull-to-refresh component down past the threshold (default 50 pixels), then lets go, the component sends a refresh action and enters the refreshing state. Your route can handle this action, fetch data from the server, then set the controller's refreshing property to false to reset to the default state. While in the refreshing state, the .pull-to-refresh element has a .refreshing class you can use for styling. When the user is pulling, it has a .pulling class. That's pretty much it!

Provide a scrollable selector that indicates the scrolling area being observed, in order to enable normal scrolling behavior when not at the top.

Both mobile touch events and desktop-browser mouse events are supported by default. Mouse events may be disabled by setting the property disableMouseEvents to true.

Installation

  • git clone <repository-url> this repository
  • cd my-addon
  • npm install

Running

Running Tests

  • npm test (Runs ember try:each to test your addon against multiple Ember versions)
  • ember test
  • ember test --server

Building

  • ember build

For more information on using ember-cli, visit https://ember-cli.com/.

Keywords

ember-addon

FAQs

Package last updated on 27 Jul 2018

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.