Comments (18)
This is the error when used ng serve
from ngx-quill-editor.
Do not worry, you can use it in the same way, I'll show you an example:
HTML CODE
<quill-editor id="detailEditTxt" name="detailEditTxt" [(ngModel)]="var_detailString"
[options]="editorOptions">
</quill-editor>
TYPE SCRIPT CODE
// Configurations
// Specific options for toolbox
public toolbarOptions = [['bold', 'italic'], ['link', 'image']];
// Set options
public editorOptions = {
placeholder: 'Write your text here ...'
, modules: {
toolbar: this.toolbarOptions
}
};
from ngx-quill-editor.
I can help you, I have integrated the project with Angular 5, what is the doubt you have?
from ngx-quill-editor.
from ngx-quill-editor.
OK, I'll explain my case:
I install:
npm ngx-quill-editor --save
in app.module.ts:
import { QuillEditorModule } from 'ngx-quill-editor';
@NgModule({
declarations: [
AppComponent
],
imports: [
BrowserModule,
QuillEditorModule,
], ...
Then, on the project:,
TS page:
public my_string: string;
HTML page:
<quill-editor name="detailEditTxt" [(ngModel)]="my_string"></quill-editor>
This will place all the text, images and links to videos that you write in the variable "my_string".
To see the result, just place a button that will run console.log (this.my_string).
Try it and tell me. In case of any error, please share it here.
Regards!
from ngx-quill-editor.
from ngx-quill-editor.
Hi!
The variable "my_string" is the data model, this can be a simple string variable or an attribute of a data model. in this example, i use the variable "v_text":
Within the attribute or variable, all the content that is being introduced in the quill control will be stored, text with format, images (these are automatically converted to base64), links to videos, etc. Everything is stored in HTML format.
Into DataBase
This would show the content inside the variable "v_text":
All that html text, you store it in database, you send it by mail, etc.
If you want to add a style sheet, what you comment is correct, your snow.css style sheet can be placed in the angular-cli.json file, in the "styles" section, example:
"styles": [
"styles.css",
"assets / styles / sidenav.css",
]
I hope I have helped you, if you have more questions, please write them here, to help you.
regards!
from ngx-quill-editor.
from ngx-quill-editor.
haa ok!,
In this web it will help you to personalize the editor:
https://quilljs.com/docs/modules/toolbar/
ngx-quill-editor is developed based on quilljs.
Regards!
from ngx-quill-editor.
from ngx-quill-editor.
from ngx-quill-editor.
What is the error?
from ngx-quill-editor.
from ngx-quill-editor.
Please, attach too your code please.
from ngx-quill-editor.
npm ngx-quill-editor --save
So 2.2.4 version got installed .
In app.module.ts file
import { QuillEditorModule } from 'ngx-quill-editor';
@NgModule({
declarations: [
AppComponent
],
imports: [
BrowserModule,
QuillEditorModule,
], ...
TS page:
public my_string: string;
HTML page:
<quill-editor name="detailEditTxt" [(ngModel)]="my_string">
Till here it was fine
It appeared with all the tools in it.
After that to customize where I needed only bold italic underline image and link
For that I used
Configurations
// Specific options for toolbox
public toolbarOptions = [['bold', 'italic'], ['link', 'image']];
// Set options
public editorOptions = {
placeholder: 'Write your text here ...'
, modules: {
toolbar: this.toolbarOptions
}
};
Initially it was working though it had one error..
For the semi-colon in the above piece of code.
Then after doing some alterations with the comma and semicolon.It gave me this error when I tried to clean build the file ng build as initially with editor options I was getting one error but rendered on chrome later when used ng build and ng serve got webpack compile failed and the lines of error above attached.
from ngx-quill-editor.
After adding it started giving error as ngx quill editor not found..Then I changed this line
import { QuillEditorModule } from 'ngx-quill-editor'; to import { QuillEditorModule } from './node_modules/ngx-quill-editor';
I'm using angular cli
from ngx-quill-editor.
1.5.0 and angular/compiler-cli version 5.0.0
from ngx-quill-editor.
mmm ok,
update the version to "ngx-quill-editor": "2.2.2" and you start again from the beginng.
When it works again, add the controls configuration.
from ngx-quill-editor.
Related Issues (20)
- AOT issue HOT 1
- How to register a custom module? HOT 3
- Disable not available
- Angular 5 HOT 6
- Type 'null' is not assignable to type 'string'
- Angular 6 Package format compliance HOT 5
- Module build failed: ....is missing from the TypeScript compilation HOT 14
- Include HTML Input Tags and Bind with Angular
- can editor set fontsize in Number(13, 14, 15 ) not in these words (small normal large huge) ?I have not seen in configration
- Changing options.readOnly doesn't enable/disable quill HOT 1
- Italic functionlity not working
- Compatibility with Angular Universal HOT 1
- Css Class name is removed after converting the content
- Cannot change font color and background color HOT 1
- Type checking errors with Angular 7 HOT 2
- img can not bind to model
- cannot detect empty content when I use backspace
- Error running text editor, I just get white screen when serving my app
- I can't add Undo/Redo Buttons to quill-editor HOT 1
- "export 'DOCUMENT' was not found in '@angular/platform-browser' Fix for Angular 8
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 ngx-quill-editor.