Title: Elixir Script as ClientLibrary Framework to Interface with Elixir/Phoenix · Issue #494 · elixirscript/elixirscript · GitHub
Open Graph Title: Elixir Script as ClientLibrary Framework to Interface with Elixir/Phoenix · Issue #494 · elixirscript/elixirscript
X Title: Elixir Script as ClientLibrary Framework to Interface with Elixir/Phoenix · Issue #494 · elixirscript/elixirscript
Description: Are there any thoughts about creating a client framework for interactions with a Phoenix Backend. Like programmatically mapping resources/routes, error handling (messages) etc. Would make sense I guess, so for example, interaction with M...
Open Graph Description: Are there any thoughts about creating a client framework for interactions with a Phoenix Backend. Like programmatically mapping resources/routes, error handling (messages) etc. Would make sense I g...
X Description: Are there any thoughts about creating a client framework for interactions with a Phoenix Backend. Like programmatically mapping resources/routes, error handling (messages) etc. Would make sense I g...
Opengraph URL: https://github.com/elixirscript/elixirscript/issues/494
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Elixir Script as ClientLibrary Framework to Interface with Elixir/Phoenix ","articleBody":"Are there any thoughts about creating a client framework for interactions with a Phoenix Backend.\r\nLike programmatically mapping resources/routes, error handling (messages) etc.\r\n\r\nWould make sense I guess, so for example, interaction with Modules, GenServers etc. \r\nOne could just get the generated script directly from the server.\r\n\r\nJust consider the following idea:\r\n\r\n```elixir\r\ndefmodule API.Accounts do\r\n use ClientInterface, \"Accounts\"\r\n \r\n api(\"getUser\", jwt, id \\\\ nil) do\r\n Accounts.get_user(id || jwt.userId)\r\n end\r\nend\r\n```\r\n\r\n```html\r\n\u003cscript src=\"/backend-api.js?module=MyAPI\"\u003e\u003c/script\u003e\r\n\u003cscript\u003e\r\nMyAPI.Accounts.getUser()\r\n .then(me =\u003e {\r\n // got the current user, as there were no id specified\r\n }).catch(e =\u003e {\r\n // handle error\r\n })\r\n\u003c/script\u003e\r\n```\r\n\r\nI think, that such a framework would make rapid development of apis and adoption of elixir very smooth. It would be possible to build other interfaces like sockets and such on top of that very straightforward.\r\n\r\nWould like to know, what the community thinks about it\r\n","author":{"url":"https://github.com/webdeb","@type":"Person","name":"webdeb"},"datePublished":"2019-12-27T18:11:30.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/494/elixirscript/issues/494"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:f3e0918d-eff1-4231-8f8d-c988f04f5051 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | AB22:15DFF5:1D570FE:2856A1F:696ABB75 |
| html-safe-nonce | c911ee578ff6abca666ba5101a1f1934cdf886cc38ee9fb0ad613a62743f5a17 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBQjIyOjE1REZGNToxRDU3MEZFOjI4NTZBMUY6Njk2QUJCNzUiLCJ2aXNpdG9yX2lkIjoiODI1MTcyOTQ3MjgwOTI1Mzc0OSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | d56a30f18bc87b996b266b1a655235c84bb89f21fbff3717b128f5423d0b9b9c |
| hovercard-subject-tag | issue:542950523 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/elixirscript/elixirscript/494/issue_layout |
| twitter:image | https://opengraph.githubassets.com/7e34cc62ec36cbc5471491fc320a4b99db4137599f9b01cc055a45ce770a7f25/elixirscript/elixirscript/issues/494 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/7e34cc62ec36cbc5471491fc320a4b99db4137599f9b01cc055a45ce770a7f25/elixirscript/elixirscript/issues/494 |
| og:image:alt | Are there any thoughts about creating a client framework for interactions with a Phoenix Backend. Like programmatically mapping resources/routes, error handling (messages) etc. Would make sense I g... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | webdeb |
| hostname | github.com |
| expected-hostname | github.com |
| None | 46ce962e0e18113ea447391b6ace8b02d4d2861e57b4fbab3658698f73d8855b |
| turbo-cache-control | no-preview |
| go-import | github.com/elixirscript/elixirscript git https://github.com/elixirscript/elixirscript.git |
| octolytics-dimension-user_id | 25870092 |
| octolytics-dimension-user_login | elixirscript |
| octolytics-dimension-repository_id | 30160313 |
| octolytics-dimension-repository_nwo | elixirscript/elixirscript |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 30160313 |
| octolytics-dimension-repository_network_root_nwo | elixirscript/elixirscript |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 30300f30bb3949de255e84a146706a3bdb5c19c9 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width