GithubHelp home page GithubHelp logo

arnemolland / figma Goto Github PK

View Code? Open in Web Editor NEW
21.0 3.0 17.0 346 KB

Figma API client written in pure Dart

Home Page: https://pub.dev/packages/figma

License: MIT License

Dart 100.00%
figma dart

figma's Introduction

figma

figma pub style: lints license

A library for interacting with Figma APIs with typed responses and data structures.

Usage

A simple usage example:

import 'package:figma/figma.dart';

main() {
  final file = FigmaClient('token').getFile('key');
}

More intricate and detail usage can be found in the examples.

Features and bugs

Please file feature requests and bugs at the issue tracker.

figma's People

Contributors

aloisdeniel avatar arnemolland avatar bigflexliu avatar bjartebore avatar jwinterday avatar timcreatedit avatar yzxben avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

figma's Issues

Better documentation

Right now, there's limited documentation, no guides and no proper examples. At the very least, the library should;

  • Include good documentation for the entire public API surface
  • Include "getting started" guide as well as guides for common use-cases
  • Include example application(s)

Don't subclass `Error` for `FigmaError`

Thanks for the great package. I think I found a little problem that should be a quick fix.

All subclasses of Error are not meant to be caught. Errors are supposed to model irrecoverable failures in the program.
https://dart.dev/language/error-handling

I would argue that errors in an API request are meant to be caught, so FigmaError should subclass Exception instead. The way it is right now means I have to ignore the avoid_catching_errors lint all the time :)

Missing `layoutGrow` property

There's an error in the Figma documentation about layoutGrow property that is documented only on Vector nodes, but which should also be present on Frame nodes since it indicates how auto-layout's children should behave.

By trying to implement auto-layout rendering, I'm quite confident that it is an issue with Figma documentation since this property is returned by the API for all auto-layout children.

image

Null safety

It would be great if the package could be migrated null safety, I will provide a pull request

Does not work with Flutter web

This package doesn't work with Flutter web due to its dependency on SecureSocket which isn't available yet for web. I'm curious why HttpClient isn't used instead?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.