-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Add importer which imports files from .md/.txt #325
Add importer which imports files from .md/.txt #325
Conversation
Sorry, firstly plz fix conflicts 🙇 |
Alright. Done. |
How do I get this? It's not in the current download. |
@GaryFurash This feature is in progress now. So wait a moment please... 🙇 |
@asmsuechan Thanks. I'll check 💡 |
browser/main/NoteList/index.js
Outdated
} | ||
|
||
const targetIndex = _.findIndex(this.notes, (note) => { | ||
return note != null && note.storage + '-' + note.key === location.query.key |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't you use strict equal? !==
And you can use template literal.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure thing.
if (filepaths === undefined) return | ||
filepaths.forEach((filepath) => { | ||
fs.readFile(filepath, (err, data) => { | ||
if (err) throw Error('File reading error: ', err) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[Question] Do you test this situation? Doesn't it crush?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Umm, I tried by hand, but the probability is quite low.
Just an idea that is related to this....what about the ability to upload a ZIP archive file that contains multiple files of any of these formats,
Boostnote would then create a Code Snippet File in Boostnote and add a sub-file/tab file for each file in the ZIP archive that is in the allowed formats. Just an idea |
browser/main/NoteList/index.js
Outdated
filepaths.forEach((filepath) => { | ||
fs.readFile(filepath, (err, data) => { | ||
if (err) throw Error('File reading error: ', err) | ||
// TODO: fill the title |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm gonna open another PR to implement a module for findTitle()
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I should use the method, so I have to wait for merging it.
#548
Is this working yet? It doesn't work on my Windows 7 or Windows 10 PC. |
@GaryFurash I'm going to try fixing it in a few days. |
@GaryFurash Well, it seems to work fine in my environment (master branch on windows 10). Please open a new issue with screenshots. |
Hi there. I implemented a function which imports files from .md or .txt.
Specifications
If someone wants what else, please comment.
TODO
I'll implement
fill a title
after #324 is merged.Future