{"id":15209273,"url":"https://github.com/socketstream/ss-ejs","last_synced_at":"2025-10-03T01:31:33.287Z","repository":{"id":11825925,"uuid":"14379522","full_name":"socketstream/ss-ejs","owner":"socketstream","description":"EJS (HTML) code wrapper for SocketStream 0.3","archived":true,"fork":false,"pushed_at":"2013-11-17T13:32:47.000Z","size":128,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-12-19T17:02:08.301Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/socketstream.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2013-11-13T23:25:44.000Z","updated_at":"2023-04-18T19:28:45.000Z","dependencies_parsed_at":"2022-08-28T11:12:17.305Z","dependency_job_id":null,"html_url":"https://github.com/socketstream/ss-ejs","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/socketstream%2Fss-ejs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/socketstream%2Fss-ejs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/socketstream%2Fss-ejs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/socketstream%2Fss-ejs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/socketstream","download_url":"https://codeload.github.com/socketstream/ss-ejs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230582806,"owners_count":18248674,"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-09-28T07:22:57.702Z","updated_at":"2025-10-03T01:31:28.023Z","avatar_url":"https://github.com/socketstream.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"SS-EJS\n===\n\nEJS (HTML) code wrapper for SocketStream 0.3\n\n\n\nInstall\n---\n\n    npm install ss-ejs\n\nUsage\n---\n\nAdd this line of code to your app.js file:\n\n    ss.client.formatters.add(require('ss-ejs'));\n\nPassing variables to your ejs view files\n---\n\nIn the app.js file, pass locals to your view template like this:\n\n\n    ss.client.formatters.add(require('ss-ejs'), {locals: {user: 'Paul'}});\n\nThen, in your views/app.ejs file, load the SocketStream headers like this:\n\n    \u003c!DOCTYPE html\u003e\n    \u003chtml lang=\"en\"\u003e\n      \u003chead\u003e\n        \u003cmeta charset=\"utf-8\"/\u003e\n        \u003c%- SocketStream %\u003e\n        \u003ctitle\u003eWelcome\u003c/title\u003e\n      \u003c/head\u003e\n\nAnd use the local variables in your ejs template like this:\n\n    \u003ch3\u003eQuick Chat Demo for \u003c%= locals.user %\u003e\u003c/h3\u003e\n\n\nTODO\n---\n\nI've noticed that how we pass local variables to our ejs template isn't flexible in terms of having multiple ejs view templates with different local variables. I will look to resolve this issue in the near future.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsocketstream%2Fss-ejs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsocketstream%2Fss-ejs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsocketstream%2Fss-ejs/lists"}