Comments (20)
adding in the following code to tinymce.js fixes this issue. No other issues arise.
scope.$on('$destroy', function() {
if (!tinyInstance) { tinyInstance = tinymce.get(attrs.id); }
if (tinyInstance) {
tinyInstance.remove();
tinyInstance = null;
}
});
I would like to see this added to the main branch, as of right now I'll have to provide a modified tinymce.js to my project
from ui-tinymce.
+1 works for me, I am using ui-router views in case that makes any difference. (I've noticed the same error in other Angular plug-ins like Angularstrap tooltip, so maybe ui-router is mis-handling scope?).
from ui-tinymce.
As I have found - it is because tinymce is not properly removed after directive scope is destroyed - so script is trying to do something on destroyed scope(and because of that - there was no $root property in scope).
This was fixed in commit 96d9275
I also had this bug, because of #84. And probably you are also using outdated version because of that.
from ui-tinymce.
Any reason jojobyte's change hasn't been added?
from ui-tinymce.
It would be good to have this fixed soon...
from ui-tinymce.
@Bryan-Turek your solution worked for me, thanks.
from ui-tinymce.
I have the same issue, and @jojobyte's fix works for me.
from ui-tinymce.
@Bryan-Turek fix worked fine for me, but I have the same problem updateing to the next verision with bower as @zxbodya. A new version number would be nice ;-)
from ui-tinymce.
In the meantime I would just modify your tinymce.js, delete the line in bower.json for ui-tinymce (after you bower install it). and modify your .gitignore to keep that path to ui-tinymce. This way it won't be overwritten and you'll always have that modified version. Only downside is, you can't grab the new version, unless you modify that one as well.
from ui-tinymce.
@jojobyte's fix worked for me as well, perhaps this patch should be incorporated?
from ui-tinymce.
Working! Thank you!
from ui-tinymce.
Bug is reproducing for me
from ui-tinymce.
Still reproduces in 0.0.5
from ui-tinymce.
@Uznick did you find a workaround ?
from ui-tinymce.
@mudassir0909 nope, still living with it.
from ui-tinymce.
😢 guess I'll use a forked repo until then
from ui-tinymce.
I switched this to $rootScope
, which is what the code should have referenced - this should now be fixed.
from ui-tinymce.
I have the same issue, and @jojobyte's fix works for me.
from ui-tinymce.
@jojobyte fix worked for me. Thanks!
from ui-tinymce.
Manually Triggering the Digest Cycle. Please use like this:
$scope.$apply(() => {
your code here that changes ng-model
});
from ui-tinymce.
Related Issues (20)
- Bower main file should be angular-ui-tinymce.js HOT 1
- Can't acces editor instance by ID HOT 2
- how to set dynamically tinymce in readonly mode ? HOT 2
- Placeholder-plugin HOT 2
- upgrade tinymce to 4.7.1 (from ~4.5.1)
- On setup, sets form as pristine
- Unable to add multiple editor HOT 1
- Tinymce in different tabs of bootstrap doesnt work
- Theme is not a constructor HOT 2
- Copy/Past HOT 3
- AngularJS directive/component in model
- how to uploadimge in local?
- using ui-tinymce with lazy loaded tynyMCE npm module HOT 2
- How to use "updateOn: 'blur'"?
- tinymce Option not working inside a custom directive HOT 1
- Is tinyMCE free library to use? HOT 1
- not showing properly tinymce editor HOT 2
- Hey I propose myself as a maintainer HOT 2
- To be Maintainer
- Is it possible to add image/ file manager within the TinyMCE?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ui-tinymce.