Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/oddbit/flutter-schema-org
JSON-LD library with Dart types for Schema.org vocabulary
https://github.com/oddbit/flutter-schema-org
dart flutter flutter-library flutter-package flutter-seo flutter-web schema-org seo
Last synced: 8 days ago
JSON representation
JSON-LD library with Dart types for Schema.org vocabulary
- Host: GitHub
- URL: https://github.com/oddbit/flutter-schema-org
- Owner: oddbit
- License: apache-2.0
- Created: 2024-03-30T02:08:25.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2024-04-03T03:06:26.000Z (8 months ago)
- Last Synced: 2024-04-20T16:09:52.695Z (7 months ago)
- Topics: dart, flutter, flutter-library, flutter-package, flutter-seo, flutter-web, schema-org, seo
- Language: Dart
- Homepage: https://pub.dev/packages/schema_org
- Size: 2.55 MB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
JSON-LD Dart classes for Schema.org vocabulary.
## Features
`schema_org` provides Dart definitions for Schema.org vocabulary that can
be exported to JSON-LD format. The typings are exposed as complete sets of
discriminated type unions, allowing for easy completions and stricter validation.You can find all available schemas on [Schema.org](https://schema.org/docs/schemas.html)
and each schema is represented in this library with the prefix `Schema`For example
- [Organization](https://schema.org/Organization) => `SchemaOrganization`
- [Person](https://schema.org/Person) => `SchemaPerson`## Usage
Call the `SchemaOrg.writeJsonLd()` method and pass it a Schema.org class that
represents your data.```flutter
SchemaOrg.writeJsonLd(
SchemaOrganization(
name: 'Oddbit',
url: 'https://oddbit.id',
logo: 'https://avatars.githubusercontent.com/u/1946799?s=200&v=4',
),
);
```![Oddbit Organization Screenshot](https://raw.githubusercontent.com/oddbit/flutter-schema-org/main/images/oddbit_organization_html.png)
## Getting involved
First of all, thank you for even considering to get involved. You are a real
super :star: and we :heart: you!All the schema definitions are auto generated by the schema_parser CLI script
that you can find in the repository folder
[`/parser`](https://github.com/oddbit/flutter-schema-org/tree/main/parser).### Reporting bugs and issues
Validating all the schemas and possible quirks of how to interpret their usage is a
huge task and we appreciate any findings and links to sources or best practices that
can help us to improve this package.We're grateful for any help that you can provide, and even better if you can provide
suggestions for how to improve the `schema_parser` script that generates all the code.