Food-Static-Data / sd

Food static data wrapper
GNU General Public License v3.0
9 stars 14 forks source link

convert image data to js object #135

Closed atherdon closed 5 years ago

atherdon commented 5 years ago

https://github.com/ChickenKyiv/awesome-food-measurements-information/blob/master/images/cooking-guide-apron-cu-cooking-times.jpg

@elnur004 you can grab it

vadim9999 commented 5 years ago

For example describe('this test prevents to any issues and problems, also to break the structure of cooking_times data', () => { test('cooking_times data files returns object', () => { expect(cooking_times).not.toBe('') }), test('cooking_times data files returns object', () => { expect(cooking_times).not.toBe('') }), test('cooking_times data files returns object', () => { expect(cooking_times).not.toBe('') }) })

vadim9999 commented 5 years ago

@elnur004 please can you create one pull request and many commits?

elnur004 commented 5 years ago

i don't know how to do this

vadim9999 commented 5 years ago

also you can run tests by

npm run tests
elnur004 commented 5 years ago

@vadim9999 i am a novice in this sphere i don't know a lot of things but i'm trying to learn

vadim9999 commented 5 years ago

you have forked repository, right? you make some changes then git add * git commit -m "comment" git push after that if you have created pull request it will automaticall add's commit to pull request(PR) if you haven't any PR you can create it

elnur004 commented 5 years ago

i have forked a long time ago but i can't see a lot of changes in there now i dont know why

vadim9999 commented 5 years ago

and what are you doing?

elnur004 commented 5 years ago

i will try to do

elnur004 commented 5 years ago

@vadim9999 what needs to do now?

vadim9999 commented 5 years ago

@elnur004 gave you Artur some task?

elnur004 commented 5 years ago

the last task was this

vadim9999 commented 5 years ago

@elnur004 I can give you task, but I don't know can you do this or not. It's need to fix some failed tests. to run tests you need

npm run test
elnur004 commented 5 years ago

to solve this task, need me to know node.js?

vadim9999 commented 5 years ago

@elnur004 yes. Do you have this?

elnur004 commented 5 years ago

i want to do. and besides this, i think it will profitable for me to learn node.js btw may i ask you some question if there will be any problem to solve this task to me?

vadim9999 commented 5 years ago

@elnur004 import and export objects from files that you had working in https://github.com/GroceriStar/sd/blob/master/src/files.js .

vadim9999 commented 5 years ago

@elnur004 I think if you will make last comment I will close this issues

elnur004 commented 5 years ago

i don't know, need me to download anything to computer to run this?

vadim9999 commented 5 years ago

@elnur004 do you mean to run tests?

elnur004 commented 5 years ago

yes

vadim9999 commented 5 years ago

to run tests you should install nodejs then in the root project

npm install

(this command will download all packages that was defined in package.json) then you can run npm run test

vadim9999 commented 5 years ago

also to know that tests is working you can in pull request besides your commit click details and see result of tests

vadim9999 commented 5 years ago

@elnur004 have you imported exported objects in files.js that you had working?

elnur004 commented 5 years ago

need me to change JSON files and export these?

vadim9999 commented 5 years ago

@elnur004 no, first you need to import object then export it in files.js. It need because to get your object from outside of package

elnur004 commented 5 years ago

@vadim9999 these JSON files confuse me may you give me some hint, please?

vadim9999 commented 5 years ago

@elnur004 in path when you want import object from .json you should use .json. when you import object from js you don't need to use filename with extension, just filename. In you case you should use just filename in path because you files have extension .js

elnur004 commented 5 years ago

@vadim9999 sorry for the question but from which file i have to export file and to which file i have to import?