Skip to content
This repository was archived by the owner on Oct 3, 2024. It is now read-only.

Update cropper when options.aspectRatio changed. #34

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

blutarche
Copy link

Added below script inside ngCropper directive in dist/ngCropper.all.js

scope.$watch('options.aspectRatio', function() {
  element.cropper('destroy').cropper(scope.options);
}, true);

@srinivasaltair
Copy link

@koorgoo Above code is very helpful and it works as expected please accept the pull request so that we can directly use it from boweror npm install without changing the repo code.

I had a question #36 regarding the issue, but this script helped me fix it.

Thanks in advance & @blutarche Thanks

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants