1NAME 2 Text::Table::CSV - Generate CSV 3 4VERSION 5 This document describes version 0.023 of Text::Table::CSV (from Perl 6 distribution Text-Table-CSV), released on 2019-11-29. 7 8SYNOPSIS 9 use Text::Table::CSV; 10 11 my $rows = [ 12 # header row 13 ['Name', 'Rank', 'Serial'], 14 # rows 15 ['alice', 'pvt', '123456'], 16 ['bob', 'cpl', '98765321'], 17 ['carol', 'brig gen', '8745'], 18 ]; 19 print Text::Table::CSV::table(rows => $rows); 20 21DESCRIPTION 22 This module provides a single function, "table", which formats a 23 two-dimensional array of data as CSV. This is basically a way to 24 generate CSV using the same interface as that of Text::Table::Tiny 25 (v0.03) or Text::Table::Org. 26 27 The example shown in the SYNOPSIS generates the following table: 28 29 "Name","Rank","Serial" 30 "alice","pvt","123456" 31 "bob","cpl","98765321" 32 "carol","brig gen","8745" 33 34FUNCTIONS 35 table(%params) => str 36 OPTIONS 37 The "table" function understands these arguments, which are passed as a 38 hash. 39 40 * rows* (aoaos) 41 42 Required. Takes an array reference which should contain one or more 43 rows of data, where each row is an array reference. 44 45 * header_row (bool) 46 47 Optional, default true. Whether to print the first row (which is 48 assumed to be the header row). 49 50HOMEPAGE 51 Please visit the project's homepage at 52 <https://metacpan.org/release/Text-Table-CSV>. 53 54SOURCE 55 Source repository is at 56 <https://github.com/perlancar/perl-Text-Table-CSV>. 57 58BUGS 59 Please report any bugs or feature requests on the bugtracker website 60 <https://rt.cpan.org/Public/Dist/Display.html?Name=Text-Table-CSV> 61 62 When submitting a bug or request, please include a test-file or a patch 63 to an existing test-file that illustrates the bug or desired feature. 64 65SEE ALSO 66 The de-facto module for handling CSV in Perl: Text::CSV, Text::CSV_XS. 67 68 See also Bencher::Scenario::TextTableModules. 69 70AUTHOR 71 perlancar <perlancar@cpan.org> 72 73COPYRIGHT AND LICENSE 74 This software is copyright (c) 2019, 2018, 2015 by perlancar@cpan.org. 75 76 This is free software; you can redistribute it and/or modify it under 77 the same terms as the Perl 5 programming language system itself. 78 79