{"id":20319570,"url":"https://github.com/nfourtythree/craft-directory-contents","last_synced_at":"2025-04-11T18:20:45.221Z","repository":{"id":141829993,"uuid":"51435545","full_name":"nfourtythree/craft-directory-contents","owner":"nfourtythree","description":"adds variable to return array of given directory content","archived":false,"fork":false,"pushed_at":"2016-02-13T20:24:35.000Z","size":7,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-25T14:12:22.209Z","etag":null,"topics":["craft-plugin","craftcms","craftcms-plugin"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nfourtythree.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-02-10T10:53:48.000Z","updated_at":"2017-07-16T18:58:26.000Z","dependencies_parsed_at":"2023-05-01T17:26:31.190Z","dependency_job_id":null,"html_url":"https://github.com/nfourtythree/craft-directory-contents","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nfourtythree%2Fcraft-directory-contents","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nfourtythree%2Fcraft-directory-contents/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nfourtythree%2Fcraft-directory-contents/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nfourtythree%2Fcraft-directory-contents/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nfourtythree","download_url":"https://codeload.github.com/nfourtythree/craft-directory-contents/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248456384,"owners_count":21106606,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["craft-plugin","craftcms","craftcms-plugin"],"created_at":"2024-11-14T18:47:22.464Z","updated_at":"2025-04-11T18:20:45.186Z","avatar_url":"https://github.com/nfourtythree.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Direct Contents plugin for CraftCMS\n\nAdds `craft.directoryContents.read(\"path/to/directory\")` variable to templates allowing passing of a directory.\n\nThe variable returns a recursive array of the directories contents.\n\nCurrently supported parameters are `path` and `ignoreFiles`. Only `path` is required.\n\nBy Default `ignoreFiles` only ignores `.DS_Store`\n\nVery early release.\n\n## Installation\n1. Download Zip\n2. Drop `directorycontents` in your plugins folder\n3. Install\n4. Go Go Go\n\n## Usage\n\n```\n// Template Tag\n{% set files = craft.directoryContents.read(\"path/to/directory\") %} // return array\n\n// or\n{% set options = {\n    path: \"path/to/dir\",\n    ignoreFiles: [\".DS_Store\", \".gitignore\", \"example.txt\"]\n} %}\n{% set files = craft.directoryContents.read(options) %}\n\n```\n\n### TODO\n- ADD ALL THE OPTIONS (e.g. depth, file type etc)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnfourtythree%2Fcraft-directory-contents","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnfourtythree%2Fcraft-directory-contents","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnfourtythree%2Fcraft-directory-contents/lists"}