All Projects → TeamHG-Memex → extract-html-diff

TeamHG-Memex / extract-html-diff

Licence: MIT license
extract difference between two html pages

Programming Languages

HTML
75241 projects
python
139335 projects - #7 most used programming language

Labels

Projects that are alternatives of or similar to extract-html-diff

Elm Package
Command line tool to share Elm libraries
Stars: ✭ 214 (+637.93%)
Mutual labels:  diff
git-tui
Collection of human friendly terminal interface for git.
Stars: ✭ 95 (+227.59%)
Mutual labels:  diff
knowledge-graph-change-language
Tools for working with KGCL
Stars: ✭ 14 (-51.72%)
Mutual labels:  diff
Ex audit
Ecto auditing library that transparently tracks changes and can revert them.
Stars: ✭ 214 (+637.93%)
Mutual labels:  diff
Dsladapter
🔥 Kotlin时代的Adapter, Dsl 的形式使用 RecyclerView.Adapter, 支持折叠展开, 树结构,悬停,情感图状态切换, 加载更多, 多类型Item,侧滑菜单等
Stars: ✭ 231 (+696.55%)
Mutual labels:  diff
vscode-diff
Compare two folders in Visual Studio Code
Stars: ✭ 66 (+127.59%)
Mutual labels:  diff
Pytest Clarity
A plugin to improve the output of pytest with colourful unified diffs
Stars: ✭ 209 (+620.69%)
Mutual labels:  diff
nano-staged
Tiny tool to run commands for modified, staged, and committed files in a GIT repository.
Stars: ✭ 347 (+1096.55%)
Mutual labels:  diff
Rxdatasources
UITableView and UICollectionView Data Sources for RxSwift (sections, animated updates, editing ...)
Stars: ✭ 2,784 (+9500%)
Mutual labels:  diff
ExtDiff
Compare documents using MS Word from the command line.
Stars: ✭ 100 (+244.83%)
Mutual labels:  diff
Awesome Website Change Monitoring
A curated list of awesome tools for website diffing and change monitoring.
Stars: ✭ 224 (+672.41%)
Mutual labels:  diff
Diff So Fancy
Good-lookin' diffs. Actually… nah… The best-lookin' diffs. 🎉
Stars: ✭ 14,806 (+50955.17%)
Mutual labels:  diff
graphql-schema-diff
📄🔄📄 Returns the diff of two GraphQL schemas. Detects dangerous and breaking changes.
Stars: ✭ 54 (+86.21%)
Mutual labels:  diff
Deck
decK: Configuration management and drift detection for Kong
Stars: ✭ 211 (+627.59%)
Mutual labels:  diff
haoide-vscode
haoide-vscode is a vscode extension for salesforce development, which is used to replace haoide
Stars: ✭ 22 (-24.14%)
Mutual labels:  diff
Openapi Diff
Utility for comparing two OpenAPI specifications.
Stars: ✭ 208 (+617.24%)
Mutual labels:  diff
ttdo
Extend tinytest with diffobj
Stars: ✭ 21 (-27.59%)
Mutual labels:  diff
go-delta
go-delta - A Go package and utility to generate and apply binary delta updates.
Stars: ✭ 25 (-13.79%)
Mutual labels:  diff
gonp
diff algorithm in Go
Stars: ✭ 42 (+44.83%)
Mutual labels:  diff
diffy
Tools for finding and manipulating differences between files
Stars: ✭ 47 (+62.07%)
Mutual labels:  diff

extract-html-diff: extract difference between two html pages

PyPI Version Build Status Code Coverage

This package allows you to extract a difference between two html pages: given pages A and B, it will try to extract parts of A that are changed in B. It uses lxml.html.diff under the hood. but provides only changed parts as HTML.

It requires Python 3 currently.

License is MIT.

Installaton

You can install the package from PyPI:

pip install extract-html-diff

Usage

You can extract diff as text:

import extract_html_diff

html = '<div> <h1>My site</h1> <div>My content</div> </div>'
other_html = '<div> <h1>My site</h1> <div>Other content</div> </div>'

extract_html_diff.as_string(html, other_html)

this will give you:

'<div><div>My content</div>  </div>'

You can also get diff as a tree (an lxml.html.HtmlElement) if you plan to do additional transformations or change serialization:

extract_html_diff.as_tree(html, other_html)

You can pass input html as str or bytes (it will be parsed with lxml.html.fromstring in this case), or as an already parsed lxml.html.HtmlElement.


define hyperiongray
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].