Comments (9)
Hi @pedrosanta ,
I think porting to ES6 or Typescript is becoming more and more necessary. I agree to abandon CoffeeScript too (which is one of top 3 most dreaded language in stackoverflow 2018 survey ).
And porting to ES6 or Typescript is also a good change to refactoring some old/abandoned code, and I'm learning ES6 too. π
Cheers, let's do this. π€
from epub-gen.
from epub-gen.
+1 for ES6.
It would also make it easier for people like me to contribute more frequently to the repo.
from epub-gen.
I'll just leave this here in case you hadn't seen it: https://github.com/decaffeinate/decaffeinate
from epub-gen.
@emagnier it took less than hour to convert this to typescript, with help of decaffeinate, and few simple types, since ES6 is still valid TypeScript you can cut some corners and disable some of default checks.
check commits from my fork, gcoda/epub-gen.
i will be glad to do it all over again, since i modified a lot of code for my needs without really digging in the logic.
from epub-gen.
Great @cyrilis!
So, if you don't have a strong opinion between those two, I would lean to migrate to ES6 at the moment (which will already allow us to upgrade the code/syntax by a lot) β and if we feel the need later, upgrade to TypeScript.
Sounds fair?
from epub-gen.
@cyrilis i just converted it to typescript, without reading code first. π
I did a bad job, but with "strict": true
option.
forked repo
Looks like it works, most likely something broke, but with some understanding of internals i will do some refactoring of my mess π
Edit: type definitions might be helpfull with current build
from epub-gen.
π for typescript
from epub-gen.
On my side, I'm definitely in favor of TypeScript.
It will probably be a little more work to add typing, but I think it's worth it, because this will bring a lot more robust codebase for sure!
However moving first to ES6 could be a first step before going on TS.
from epub-gen.
Related Issues (20)
- Alternative: cpiber/epub-gen-memory for both node and browser
- Error with image URL HOT 3
- Custom fonts not getting applied in Epub Reader/Kindle Previewer
- The process randomly stop when downloading lots of images HOT 2
- Epub to html HOT 1
- Handle images which starts with relative path HOT 2
- Missing Hard timeout & Retry mechanism when downloading images. HOT 2
- insert video or audio into epub HOT 2
- Error: ENOTDIR, not a directory HOT 2
- fixed layout or reflowable layout
- Images and fonts do not appear on Apple Books HOT 3
- Custom ids gets converted to something another
- verbose: false outputs some logs
- verbose: false not working
- Showing different pub on different reader.
- Add tempDir option to documentation HOT 1
- a couple of bugs when using epub-gen HOT 1
- Object prototype may only be an Object or null: undefined
- [Question] Remove Table of Contents
- Please mark epub-gen as deprecated if it's no longer maintained. HOT 1
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 epub-gen.