Ngx-quill: Uncaught ReferenceError: require is not defined

Created on 3 May 2018  Â·  23Comments  Â·  Source: KillerCodeMonkey/ngx-quill

i use angular 5.2.10 and i install ngx -quill
image
and my editor is show
image

but theare hava some error .. Can you take a look ...thanks

image
image

image
image
is my jquery problem ?

Most helpful comment

one step after another:
check this out: https://github.com/KillerCodeMonkey/ngx-quill/issues/172
An issue to angular-cli is linked.

All 23 comments

image
and this problem photo

Seems like a Problem with Your build process... Never had this Problem with
Systemjs, webpack or ngcli

tokaika notifications@github.com schrieb am Do., 3. Mai 2018, 12:53:

[image: image]
https://user-images.githubusercontent.com/14201898/39572814-46d20294-4f03-11e8-8714-f9c47cf07779.png
and this problem photo

—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/KillerCodeMonkey/ngx-quill/issues/170#issuecomment-386257451,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACKOYIxfdgpLSxfV6NiWpc8Fn5m_b-tNks5tuuG_gaJpZM4Tw3aV
.

Seems like You are using angular universal. There are some Closed issues
here to Get IT Working. It does Not work out of the Box, because quilljs
needs the Document

Bengt Weiße bengtler@googlemail.com schrieb am Do., 3. Mai 2018, 12:59:

Seems like a Problem with Your build process... Never had this Problem
with Systemjs, webpack or ngcli

tokaika notifications@github.com schrieb am Do., 3. Mai 2018, 12:53:

[image: image]
https://user-images.githubusercontent.com/14201898/39572814-46d20294-4f03-11e8-8714-f9c47cf07779.png
and this problem photo

—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/KillerCodeMonkey/ngx-quill/issues/170#issuecomment-386257451,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACKOYIxfdgpLSxfV6NiWpc8Fn5m_b-tNks5tuuG_gaJpZM4Tw3aV
.

yes 。。i am using angular5 universal 。。。it seems like to config webpack。。。
I am a back-end programmer。。 Not familiar with webpack. I am also the first to use angular5+ webapi。。so。。。did i forget something?

How should I know :).
I do not know your project or code.

You could check my demo-repo there is a webpack.config

ok。。。thank you。。。

@tokaika any updates? could you fix it?

image
sorry reply you later。。I don't want to use webpack in the Angula environment. I didn't configure it. Anyway, that mistake does not affect that use of this editor. I didn't deal with this mistake on my own website。😄

I am getting the same problem with angular 6 and I'm not using universal.

/edit: I downgraded to angular 5.2.10 and CLI 1.7.4, same issue I'm afraid.

Than You should Check Your buildprocess

Check my Demo Repo. It is also Working with angular cli

Fergal Moran notifications@github.com schrieb am Sa., 5. Mai 2018, 20:31:

I am getting the same problem with angular 6 and I'm not using universal.

—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/KillerCodeMonkey/ngx-quill/issues/170#issuecomment-386825803,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACKOYCJHBzgnBoUxGt9iQOEKPrZbOw_Fks5tvfAQgaJpZM4Tw3aV
.

Yeah - I just figured the issue. I had added "../node_modules/ngx-quill/bundles/ngx-quill.umd.js" to the scripts section in .angular-cli.json. The README suggested I should, I obviously misread it.

i cannot understand your sentence。。i had added "../node_modules/ngx-quill/bundles/ngx-quill.umd.js" in angular-cli.json. i have this issue。。。you mean delete it and will be right?@fergalmoran

nope you have to add it. maybe you missed some other thirdparty libraries?

@tokaika I'm using angular cli so I don't need to add it, it's already added by the module loader.
All I have to add in .angular-cli.json is

"../node_modules/quill/dist/quill.js",

I have the same issue with angular 6. I include 2 scripts to angular.json
"scripts": [
"node_modules/quill/dist/quill.js",
"node_modules/ngx-quill/bundles/ngx-quill.umd.js"
]

Also I have other error with quill: INLINE_BLOT

2018-05-07 21 03 05

Try to remove ngx-quill.umd.js from the scripts array, like the others did :)

Am 07.05.2018 um 20:04 schrieb lichkovskyi notifications@github.com:

I have the same issue with angular 6. I include 2 scripts to angular.json
"scripts": [
"node_modules/quill/dist/quill.js",
"node_modules/ngx-quill/bundles/ngx-quill.umd.js"
]

https://user-images.githubusercontent.com/21039970/39716863-34d8133c-523a-11e8-9be8-946bfac138e1.png
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/KillerCodeMonkey/ngx-quill/issues/170#issuecomment-387151483, or mute the thread https://github.com/notifications/unsubscribe-auth/ACKOYFkC0_0iJY6sorCuaVeJsPJhE1Evks5twIypgaJpZM4Tw3aV.

ok。。i will try。。。let me give this project a star。。。

:D and close this issue if you resolved it. really strange. i don't got this during my tests with angular-cli

@KillerCodeMonkey yes require fixed, but INLINE_BLOT is present. I have this when build with production mode

ok let me find the close button。。

one step after another:
check this out: https://github.com/KillerCodeMonkey/ngx-quill/issues/172
An issue to angular-cli is linked.

Like everyone said, I had to remove "node_modules/ngx-quill/bundles/ngx-quill.umd.js" from the angular.json in angular v6 to get rid of the error....

I added already a Note in the readme ;). Glad You solved it

anu1rag notifications@github.com schrieb am Mi., 6. Juni 2018, 19:23:

Like everyone said, I had to remove
"node_modules/ngx-quill/bundles/ngx-quill.umd.js" from the angular.json in
angular v6 to get rid of the error....

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/KillerCodeMonkey/ngx-quill/issues/170#issuecomment-395148186,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACKOYJaX0XLmr0XKkMPBkVNyfYqpgd3lks5t6BACgaJpZM4Tw3aV
.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

EventectiveNButler picture EventectiveNButler  Â·  21Comments

ThomasOliver545 picture ThomasOliver545  Â·  24Comments

victorevox picture victorevox  Â·  99Comments

ShaneJohnsonCC picture ShaneJohnsonCC  Â·  18Comments

manandkumaar picture manandkumaar  Â·  26Comments