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

Convert diff match patch to typescript #1

Open
rgbkrk opened this issue Feb 22, 2019 · 0 comments
Open

Convert diff match patch to typescript #1

rgbkrk opened this issue Feb 22, 2019 · 0 comments

Comments

@rgbkrk
Copy link
Contributor

rgbkrk commented Feb 22, 2019

I posted in google/diff-match-patch to see if they'd be open to a Typescript version (ref google/diff-match-patch#58)

Right now I'm working with a vendorized copy of diff-match-patch as part of CoCalc's code base. I'm considering converting diff-match-patch to typescript as the rest of cocalc's repository is switching over to typescript.

However, I view the source of truth for the implementation to be here in this repository (just like the npm package for diff-match-patch from @JackuB et. al. defers to here). Instead of modifying it "internally", I'd like to contribute upstream here.

I would assume we'd still make the compile target match what's documented in the wiki:

it works in Netscape 4, Internet Explorer 5.5, and all browsers released since the year 2000

As part of this, I'd keep it closely aligned with @types/diff-match-patch.

Response from @NeilFraser:

Hi Kyle,

Yes, we would be interested in a TypeScript version. It would solve a lot of problems with trying to shoehorn the JS version into TS applications while keeping various type checkers happy.

I worked on a TS version a few months ago, and made considerable progress. However, other things got in the way, and I had to put it to one side. It also became apparent to me that I'm the wrong person to make design decisions in TS since I have no expertise in this language. Here's what I have so far, maybe it would be a good starting point: https://neil.fraser.name/temp/typescript.zip

Prior to moving our vendorized copy into this new library, I'm going to contribute to google/diff-match-patch and keep folks updated here.

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

1 participant