interactive_json_preview
0.1.0, released 2 years ago by an unverified publisher
An interactive JSON viewer widget with collapsible and expandable sections.
What it does
Provides a pretty UI widget to view JSON data hierarchically. Allows users to collapse and expand complex JSON objects and lists at a glance to improve readability.
AI-written summary of version 0.1.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to display debug or API JSON data inside your Flutter application.
- You want users or developers to easily navigate nested JSON structures.
Skip it when
- You need a backend data serialization layer or codegen tool.
- You are looking for state management or local storage solutions.
Strengths
- Simple integration as a standard Flutter widget.
- Supports collapsible sections for better readability of complex payloads.
Weaknesses
- Limited to visualization and does not provide advanced editing capabilities out of the box.
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 0
import 'package:flutter/material.dart';
import 'package:interactive_json_preview/interactive_json_preview.dart';
void main() => runApp(const MyApp());
class MyApp extends StatelessWidget {
const MyApp({super.key});
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
body: InteractiveJsonPreview(data: {'name': 'Yeikel', 'age': 24}),
),
);
}
}Alternatives
Packages that do the same job and could replace interactive_json_preview.
- sticky_and_expandable_list
Grouped list with sticky headers and expandable sections for CustomScrollView
50Compare - tap_builder
A simple widget for building interactive areas with customizable visual effects.
50Compare - sliver_expandable
A Sliver Flutter widget that expands or collapses another child Sliver widget.
47Compare - collapsible
A widget that collapses and expands its child by clipping it.
47Compare