flutter_view 1.0.1

  • Readme
  • Changelog
  • Example
  • Installing
  • 3

flutter_view #

A new way to develop your app

Available components #

  • View
  • ...

Usage #

Supported styles #

  • alignItems
  • aspectRatio
  • border
  • borderTop
  • borderBottom
  • borderLeft
  • borderRight
  • direction
  • flex
  • flexDirection
  • width
  • height
  • justifyContent
  • margin
  • padding
  • backgroundColor
  • opacity
  • elevation
  • shadow
  • borderRadius

[0.0.1] - TODO: Add release date.

  • TODO: Describe initial release.

example/example.dart

import 'package:flutter/material.dart';
import 'package:flutter_view/flutter_view.dart';

class HomePage extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Center(
        child: View(
          style: styles['container'],
          children: [
            View(style: styles['blue']),
            View(style: styles['red']),
            View(style: styles['blue']),
          ],
        ),
      ),
    );
  }
}

const styles = StyleSheet.create({
  'container': const Style(
    backgroundColor: Colors.yellow,
    height: 200,
    alignItems: AlignItems.stretch,
    flexDirection: FlexDirection.column,
    border: BorderSide(color: Colors.red, width: 2),
    padding: EdgeInsets.all(24),
    margin: EdgeInsets.all(24),
    borderRadius: BorderRadius.all(Radius.zero),
    elevation: 6,
  ),
  'blue': const Style(
    backgroundColor: Colors.blue,
    flex: 1,
  ),
  'red': const Style(
    backgroundColor: Colors.red,
    flex: 2,
  ),
});

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  flutter_view: ^1.0.1

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter pub get

Alternatively, your editor might support pub get or flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:flutter_view/flutter_view.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
6
Health:
Code health derived from static analysis. [more]
--
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
--
Overall:
Weighted score of the above. [more]
3
Learn more about scoring.

This package is not analyzed, because it is discontinued.

Health issues and suggestions

Document public APIs. (-0.42 points)

99 out of 101 API elements have no dartdoc comment.Providing good documentation for libraries, classes, functions, and other API elements improves code readability and helps developers find and use your API.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.1.0 <3.0.0