Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/blocknotes/gumbo-crystal
Crystal C bindings for Gumbo library
https://github.com/blocknotes/gumbo-crystal
crystal gumbo
Last synced: about 1 month ago
JSON representation
Crystal C bindings for Gumbo library
- Host: GitHub
- URL: https://github.com/blocknotes/gumbo-crystal
- Owner: blocknotes
- License: mit
- Archived: true
- Created: 2017-01-04T09:40:46.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2020-04-12T15:55:09.000Z (over 4 years ago)
- Last Synced: 2024-08-01T17:35:34.101Z (4 months ago)
- Topics: crystal, gumbo
- Language: Crystal
- Size: 21.5 KB
- Stars: 3
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
- awesome-crystal - gumbo-crystal - Bindings for [Gumbo](https://github.com/google/gumbo-parser), an HTML5 parsing library made by Google (HTML/XML Parsing)
- awesome-crystal - gumbo-crystal - Bindings for [Gumbo](https://github.com/google/gumbo-parser), an HTML5 parsing library made by Google (HTML/XML Parsing)
README
# gumbo-crystal - PROJECT UNMAINTAINED [![Build Status](https://travis-ci.org/blocknotes/gumbo-crystal.svg)](https://travis-ci.org/blocknotes/gumbo-crystal)
> *This project is not maintained anymore*
>
> *If you like it or continue to use it fork it please.** * *
* * *Crystal C bindings for Gumbo library, an HTML5 parsing library made by Google - see [gumbo-parser](https://github.com/google/gumbo-parser)
**NOTE**: actually not all functions are mapped - if you find something missing [contact me](http://www.blocknot.es/me)
## Requirements
- *gumbo* must be installed - see [installation](https://github.com/google/gumbo-parser#installation)
- *pkg-config* must be available## Installation
Add this to your application's `shard.yml`:
```yaml
dependencies:
gumbo-crystal:
github: blocknotes/gumbo-crystal
```## Usage
Wrapper access:
```ruby
require "gumbo-crystal"
output = Gumbo::Output.new LibGumbo.gumbo_parse "A test
" # wrapper init
p output.root.type
output.uninitialize # wrapper deinit
```Direct lib access:
```ruby
require "gumbo-crystal"
output = LibGumbo.gumbo_parse "A test
" # lib init
p output.value.root.value.type
LibGumbo.gumbo_destroy_output Gumbo::DefaultOptions, output # lib deinit
```## More examples
See [examples](https://github.com/blocknotes/gumbo-crystal/tree/master/examples) folder.
## Contributors
- [Mattia Roccoberton](http://blocknot.es) - creator, maintainer, Crystal fan :)