jwt_decode_full
0.9.2, released 4 years ago by dbilgin.com
A JWT decoder to extract headers, payload, expiration date, and issued date.
WASM-ready
What it does
Decodes JSON Web Tokens (JWT) to extract the header, payload, expiration date, and issued date. It also provides a check to see if the token is expired.
AI-written summary of version 0.9.2, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to read claims and expiration data from a JWT on the client side
- You want a simple utility function to decode tokens without verification overhead
Skip it when
- You need to cryptographically verify or sign JWTs on the client side
- You require complex backend token generation and management
Strengths
- Simple and straightforward usage with a single main function
- Extracts expiration and issued dates out of the box
- Supports multiple platforms including Android, iOS, Web, Windows, macOS, and Linux
Weaknesses
- Limited to decoding and does not support token generation or cryptographic signature verification
- Not documented for advanced security customization
Setup
- Kind
- Pure Dart
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 0
import 'package:jwt_decode_full/jwt_decode_full.dart';
final jwtData = jwtDecode(myToken);
print('header: ${jwtData.header}');
print('payload: ${jwtData.payload}');
print('isExpired: ${jwtData.isExpired}');Alternatives
Packages that do the same job and could replace jwt_decode_full.