Git Product home page Git Product logo

ember-cli-clock's People

Contributors

andrewvy avatar arohr avatar jerel avatar turbo87 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

ember-cli-clock's Issues

Service wont start unless I console log clock

So I am trying to inject the clock service in my model. But it will not start unless I interact with the clock service.

clock: Ember.inject.service('booking-counter'),
  isAvailable: Ember.computed('deadline', 'isbookable', 'clock.time', 'clock', function() {
    console.log(this.get('clock'));

    if(!this.get('isbookable')) {
      return false;
    }


    return moment(this.get('deadline')) > moment();
  })

If I take out the console log the service will not start. Any ideas on what I am doing wrong?

Ember 2.0 warning

In Ember 1.13 I am getting the following warning:

DEPRECATION: In Ember 2.0 service factories must have an `isServiceFactory` property set to true.
You registered (unknown mixin) as a service factory. Either add the `isServiceFactory` property
to this factory or extend from Ember.Service.

Seems like app/services/clock.js should be extending Ember.Service instead of Ember.Object

Doesn't scaffold property in a pod structure

When a project is configured to use a pod structure, this addon doesn't scaffold into the appropriate location.

expected (example assumes config/environment.js to have no podModulePrefix set)

ember g clock my-clock --pod

installing service
  create app/my-clock/service.js
installing service-test
  create tests/unit/my-clock/service-test.js

actual

ember g clock my-clock --pod

installing service
  create app/services/my-clock.js

Running the app will give an import error: Uncaught Error: Cannot find module 'my-project/services/my-clock' and is resolved upon moving the file to the appropriate pod structure location.

Request: Initialise clock to number of seconds past the hour

I'm happy to write this and submit a PR, but I want to know if it's a) in scope and b) wanted before I write it.

Basically, the use case is having Clock's hour/quarter/five/minute methods tick at the same time (or close enough) to wall clock time, so properties that should update on the hour/minute/etc can just observe clock.method instead of doing some other tricky things

The easiest way I can see to do that is to set the initial value to be seconds past the hour or seconds past midnight.

Would this be valuable?

Can't define timezone

In its API, there is no way to define and use a specific timezone, which can differ from the user country.

Upgrade to ember-cli-babel@^6.0.0

This addon is outdated with the recent Ember versions

[email protected]:
  version "2.1.1"
  resolved "https://registry.yarnpkg.com/ember-cli-clock/-/ember-cli-clock-2.1.1.tgz#342d18f14eddc855dd91d448e85296d6a2482077"
  dependencies:
    ember-cli-babel "^5.1.5"
$> ember -v

ember-cli: 2.14.1
node: 8.2.1
os: darwin x64

Update package.json

I found your lib through npm search and all the links there, from package.json, are inaccessible. Fortunately there was a link to the demo page in the README.md and a link on the demo page to Github.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.