Skip to content
This repository was archived by the owner on May 25, 2019. It is now read-only.

Commit 64b9c25

Browse files
committed
chore: re-allow textarea tags
Sorry I change my mind. We need feedbacks on possible problem with it. So it's not a solution to just prohibit it...
1 parent fcad0ce commit 64b9c25

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ Finally, add the directive to your html,
3535
as attribute :
3636

3737
```html
38-
// Not well supported yet
39-
// <textarea ui-codemirror></textarea>
38+
// Not well supported yet but still... We need feedbacks to improve it...
39+
<textarea ui-codemirror></textarea>
4040

4141
<div ui-codemirror></div>
4242
```

src/ui-codemirror.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ angular.module('ui.codemirror', [])
2626
value = iElement.text();
2727

2828
if (iElement[0].tagName === 'TEXTAREA') {
29-
throw new Error('NOPE');
30-
// codeMirror = window.CodeMirror.fromTextArea(iElement[0], {
31-
// value: value
32-
// });
29+
// Might bug but still ...
30+
codeMirror = window.CodeMirror.fromTextArea(iElement[0], {
31+
value: value
32+
});
3333
} else {
3434
iElement.html('');
3535
codeMirror = new window.CodeMirror(function(cm_el) {

0 commit comments

Comments
 (0)