{"id":15342191,"url":"https://github.com/joshtynjala/openfl-custom-app-main-sample","last_synced_at":"2026-02-27T05:37:31.868Z","repository":{"id":136811180,"uuid":"611975388","full_name":"joshtynjala/openfl-custom-app-main-sample","owner":"joshtynjala","description":"A sample OpenFL project that customizes the haxe/ApplicationMain.hx template file","archived":false,"fork":false,"pushed_at":"2023-11-16T22:19:06.000Z","size":11,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-17T04:00:08.335Z","etag":null,"topics":["haxe","openfl","openfl-samples"],"latest_commit_sha":null,"homepage":"","language":"Haxe","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/joshtynjala.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"joshtynjala","patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2023-03-09T23:44:02.000Z","updated_at":"2025-01-07T22:09:22.000Z","dependencies_parsed_at":"2023-11-16T23:14:20.858Z","dependency_job_id":null,"html_url":"https://github.com/joshtynjala/openfl-custom-app-main-sample","commit_stats":{"total_commits":8,"total_committers":1,"mean_commits":8.0,"dds":0.0,"last_synced_commit":"02098d5b4132162a38eb142e505e098acb6fa360"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshtynjala%2Fopenfl-custom-app-main-sample","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshtynjala%2Fopenfl-custom-app-main-sample/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshtynjala%2Fopenfl-custom-app-main-sample/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshtynjala%2Fopenfl-custom-app-main-sample/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/joshtynjala","download_url":"https://codeload.github.com/joshtynjala/openfl-custom-app-main-sample/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247226196,"owners_count":20904464,"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":["haxe","openfl","openfl-samples"],"created_at":"2024-10-01T10:42:32.536Z","updated_at":"2026-02-27T05:37:31.863Z","avatar_url":"https://github.com/joshtynjala.png","language":"Haxe","funding_links":["https://github.com/sponsors/joshtynjala"],"categories":[],"sub_categories":[],"readme":"# OpenFL custom _ApplicationMain.hx_ template\n\nThe [OpenFL](https://openfl.org) library for Haxe contains a number of template files that are used when building a project. You can find them in the [_assets/templates_](https://github.com/openfl/openfl/tree/develop/assets/templates) directory. Using the `\u003ctemplate\u003e` element in _project.xml_, it's possible to replace one or more of these template files with custom versions, on a per-project basis, and without forking OpenFL.\n\nThis sample project contains a directory named [_custom-templates_](https://github.com/joshtynjala/openfl-custom-app-main-sample/tree/main/custom-templates). It is configured in [_project.xml_](https://github.com/joshtynjala/openfl-custom-app-main-sample/tree/main/project.xml) like this:\n\n```xml\n\u003ctemplate path=\"custom-templates\"/\u003e\n```\n\nInside [_custom-templates_](https://github.com/joshtynjala/openfl-custom-app-main-sample/tree/main/custom-templates), there's a file at [_haxe/ApplicationMain.hx_](https://github.com/joshtynjala/openfl-custom-app-main-sample/tree/main/custom-templates/haxe/ApplicationMain.hx). The relative path to this file matches the file named [_haxe/ApplicationMain.hx_](https://github.com/openfl/openfl/tree/develop/assets/templates/haxe/ApplicationMain.hx) inside OpenFL's [_assets/templates_](https://github.com/openfl/openfl/tree/develop/assets/templates) directory.\n\nThe custom [_haxe/ApplicationMain.hx_](https://github.com/joshtynjala/openfl-custom-app-main-sample/tree/main/custom-templates/haxe/ApplicationMain.hx) template file contains several `trace()` calls during the OpenFL initialization process. To confirm that the custom [_haxe/ApplicationMain.hx_](https://github.com/joshtynjala/openfl-custom-app-main-sample/tree/main/custom-templates/haxe/ApplicationMain.hx) is being used by the project, compile and run, and check the debug console for output.\n\n```sh\nopenfl test html5\n```\n\nThis custom [_haxe/ApplicationMain.hx_](https://github.com/joshtynjala/openfl-custom-app-main-sample/tree/main/custom-templates/haxe/ApplicationMain.hx) is a simplified version of the default one used by OpenFL. It doesn't create a preloader or load any assets, and it removes the macros that enable some more advanced features that most projects don't need.\n\nSample created by [Josh Tynjala](https://github.com/sponsors/joshtynjala), the author of [Feathers UI](https://feathersui.com/) and a member of the [OpenFL](https://openfl.org/) leadership team.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoshtynjala%2Fopenfl-custom-app-main-sample","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjoshtynjala%2Fopenfl-custom-app-main-sample","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoshtynjala%2Fopenfl-custom-app-main-sample/lists"}