Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

image upload end point is not working | editor is not taking config info #55

Open
hkmsadek opened this issue May 31, 2020 · 2 comments
Open

Comments

@hkmsadek
Copy link

I am trying to upload an image. I have config set up like this just for test

               config: {
				image: {
				// Like in https://github.com/editor-js/image#config-params
				endpoints: {
					byFile: 'http://localhost:8090/image',
					byUrl: 'http://localhost:8090/image-by-url',
				},
				field: 'image',
				types: 'image/*',
				},
			},```

and 

<editor
ref="editor"
autofocus
holder-id="codex-editor"
save-button-id="save-button"
:init-data="initData"
@save="onSave"
:config="config"

                        />

but it's not taking the config options and instead it send data to the current page url with a post request. Any idea why?
@thebilljustin
Copy link

you have to change your endpoints in byFileand byUrl to a working backend endpoint for uploading images

@calrloco
Copy link

calrloco commented Feb 16, 2021

hi im a bit late but if somebody got the same issue i have a fix, the problem is that inside tools you have to specify image property and inside of it you have to specify again config specific to that tool.

import image after installing it at the top of the script
import Image from "@editorjs/image";

config2

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

No branches or pull requests

3 participants