cooky 1.0.1

  • Example
  • Installing
  • Versions
  • 82

Cooky #

An HTTP Cookies implementation for the client.

Usage #

import 'package:cooky/cooky.dart' as cookie;

setCookie() async {
  cookie.set('key', 'value');

See our example/example.dart for a more complete example.

Changelog #

1.0.1 #

  • Minor change: Use instead of building the date with DateTime.fromMillisecondsSinceEpoch(/* etc... */)

1.0.0 #

  • Initial commit


import 'package:cooky/cooky.dart' as cookie;

main() async {
  // Create a session cookie:
  cookie.set('key', 'value');

  // Create a cookie that expires in a week:
  cookie.set('key', 'value', maxAge: new Duration(days: 7));

  // Create a cookie that is valid for a certain path and domain:
  cookie.set('key', 'value', path: '/test', domain: '');

  // Read a cookie:
  var value = cookie.get('key');

  // Delete a cookie:

Use this package as a library

1. Depend on it

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

  cooky: ^1.0.1

2. Install it

You can install packages from the command line:

with pub:

$ pub get

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

3. Import it

Now in your Dart code, you can use:

import 'package:cooky/cooky.dart';
Version Uploaded Documentation Archive
1.0.1 Aug 9, 2018 Go to the documentation of cooky 1.0.1 Download cooky 1.0.1 archive
1.0.0 Aug 9, 2018 Go to the documentation of cooky 1.0.0 Download cooky 1.0.0 archive
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
Learn more about scoring.

We analyzed this package on Apr 15, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.2.0
  • pana: 0.12.14


Detected platforms: web

Primary library: package:cooky/cooky.dart with components: html.

Maintenance suggestions

The package description is too short. (-14 points)

Add more detail to the description field of pubspec.yaml. Use 60 to 180 characters to describe the package, what it does, and its target use case.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=1.22.0 <3.0.0
intl ^0.15.7 0.15.8
Transitive dependencies
path 1.6.2
Dev dependencies
grind_publish ^0.0.2
grinder ^0.8.3
test ^1.3.0