{"id":19970247,"url":"https://github.com/webdeveric/secret-codes","last_synced_at":"2026-05-08T23:03:06.951Z","repository":{"id":27147120,"uuid":"30616080","full_name":"webdeveric/secret-codes","owner":"webdeveric","description":"Really simple easter eggs.","archived":false,"fork":false,"pushed_at":"2015-04-22T05:35:17.000Z","size":220,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-12T09:12:40.949Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://webdeveric.github.io/secret-codes/","language":"JavaScript","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/webdeveric.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":"2015-02-10T21:41:53.000Z","updated_at":"2015-04-22T05:30:16.000Z","dependencies_parsed_at":"2022-08-21T10:31:34.938Z","dependency_job_id":null,"html_url":"https://github.com/webdeveric/secret-codes","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/webdeveric%2Fsecret-codes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webdeveric%2Fsecret-codes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webdeveric%2Fsecret-codes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webdeveric%2Fsecret-codes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/webdeveric","download_url":"https://codeload.github.com/webdeveric/secret-codes/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241404419,"owners_count":19957655,"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":[],"created_at":"2024-11-13T02:53:39.047Z","updated_at":"2026-05-08T23:03:01.911Z","avatar_url":"https://github.com/webdeveric.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Secret Codes\n\nReally simple easter eggs.\n\n**Demo** http://webdeveric.github.io/secret-codes/\n\n## Load the scripts\n\n```html\n\u003cscript src=\"SecretCode.js\"\u003e\u003c/script\u003e\n\u003cscript src=\"SecretCodeManager.js\"\u003e\u003c/script\u003e\n```\n\nThese scripts can also be loaded with RequireJS, if you're into that kind of thing.\n\n## Example usage\n\n```js\nvar manager = new SecretCodeManager();\n\nmanager.add( \"KONAMI\", function( code, manager ) {\n    console.log(\"Konami code called!\");\n} );\n\n// Since the Konami code is popular, I've added a shortcut method.\nmanager.konami( function( code, manager ) {\n    console.log(\"Konami code called!\");\n} );\n\nmanager.add( \"yourcodehere\", function( code, manager ) {\n    // Do something here\n} );\n```\n\nA code can be a string or an array of keyCodes. I recommend using strings since you can use aliases within them. \n\n\n## Aliases\n\nI have provided some aliases so you don't have to know the keyCodes to keys like the up or down arrows.\nAliases usually are just Sting key = Int value, but they are more flexible than that.\nYou can put an alias inside another alias and it will recursively parse it to get the keyCodes it needs to look for.\n\nFor example, the Konami code alias is defined like this:\n\n```js\n\"KONAMI\": \"up up down down left right left right b a\"\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebdeveric%2Fsecret-codes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwebdeveric%2Fsecret-codes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebdeveric%2Fsecret-codes/lists"}