Security News
38% of CISOs Fear They’re Not Moving Fast Enough on AI
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
@joplin/onenote-converter
Advanced tools
This package is used to process OneNote backup files and output HTML that Joplin can import.
The code is based on the projects created by https://github.com/msiemens
We adapted it to target WebAssembly, adding Node.js functions that could interface with the host machine. For that to happen we are using custom-made functions (see node_functions.js
) and the Node.js standard library (see src/utils.rs
).
The requirement for this project was to simplify the migration process from OneNote to Joplin. The starting point of this migration is to export the notebook from OneNote as a zip
file containing files in the binary format used by OneNote.
The process looks like this:
onenote-converter
to read and convert the binary files to HTML (this project).See the InteropService_Importer_OneNote
class in the lib
project for details.
The OneNote drawing feature uses <svg>
tags to save user drawings. Joplin doesn't support SVG rendering due to security concerns, so we added a step to extract the <svg>
elements as SVG images, replacing them with <img>
tags.
For each HTML file, we:
svg
nodes.svg
node with an img
node that has a unique title, which will be used as the resource name.img
tags.After this, the HTML should look the same and is ready to be imported by the Importer HTML service.
- onenote-converter
- package.json -> where the project is built
- node_functions.js -> where the custom-made functions used inside rust goes
...
- pkg -> artifact folder generated in the build step
- onenote_converter.js -> main file
...
- src
- lib.rs -> starting point
To work with the project you will need:
When working with the Rust code you will probably rather run yarn buildDev
since it is faster and it has more logging messages (they can be disabled in the macro log!()
)
During development, it will be easier to test it where this library is called. InteropService_Importer_Onenote.ts
is the code that depends on this and already has some tests.
We don't require developers that won't work on this project to have Rust installed on their machine. To make this work we:
pkg/onenote_converter.js
).IS_CONTINUOUS_INTEGRATION
is not set (see build.js
).IS_CONTINUOUS_INTEGRATION
is not set (see lib/services/interop/InteropService_Importer_OneNote.test.ts
).The tests should still run on CI since IS_CONTINUOUS_INTEGRATION
is used there.
We are using WebAssembly with Node.js calls to the file system, reading and writing files and directories, which means it is not isolated (no more than Node.js is, for that matter).
FAQs
Used to import a OneNote archive into Joplin
The npm package @joplin/onenote-converter receives a total of 0 weekly downloads. As such, @joplin/onenote-converter popularity was classified as not popular.
We found that @joplin/onenote-converter demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
Research
Security News
Socket researchers uncovered a backdoored typosquat of BoltDB in the Go ecosystem, exploiting Go Module Proxy caching to persist undetected for years.
Security News
Company News
Socket is joining TC54 to help develop standards for software supply chain security, contributing to the evolution of SBOMs, CycloneDX, and Package URL specifications.