-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Interactive Playground #348
Conversation
This is very cool. Nice work! 💯 |
Happy to have this merged as-is if you are happy. We can look to move to a GH org later. |
👍 |
@@ -38,6 +38,10 @@ enum class ClientCodeGenTargetType(val description: String) { | |||
OPEN_FEIGN("Generate OpenFeign client."); | |||
|
|||
override fun toString() = "`${super.toString()}` - $description" | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm guessing this is just an unrelated refactor? I have no issue with it either way.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this is only to allow referencing the default setting from both the CLI and the Playground.
Great! Thanks for taking a look! I would like to configure automatic deployment to Fly.io, and that requires configuring a repository secret |
Too prominent? 🙈 https://github.com/cjbooms/fabrikt/blob/5c7161cc9bee23bc4c97a70ea8bde0d8525b4a42/README.md#try-fabrikt-online |
Or even as a tip? https://github.com/ulrikandersen/fabrikt/blob/5397e9d9ef981fef64c473b354b3b9179908cc7c/README.md Depends on how much you believe in the idea. |
What about reducing the intro and placing it immediately after? |
Are you sure you can't already configure ENV variables? If not, sure I can add them. Ping me on gchat: cjbooms at gmail, or let me know your preferred comms. |
I like that! I've updated the PR.
I cannot access the Settings tab at all. I'll reach out via gchat 👍 |
I added the possibility to deeplink to a set of settings. Perhaps that's useful when debugging an issue. Spec will still have to be input manually as we would otherwise need to store it somewhere (could be implemented at a later stage). |
@cjbooms I believe this is good to go, but please feel free to take a final look and perhaps also test the deeplinking! |
I am blown away by this feature. It is so cool! 💯 |
What if we gave everyone the opportunity to try Fabrikt with minimal investment? Could it motivate people to invest the time and effort needed to integrate Fabrikt into their projects and thereby drive adoption? What would it take to build such a thing?
This idea sparked the creation of an initial version of an interactive playground.
While it brings absolutely zero improvements to the code generation aspects of Fabrikt, I had fun making it, and perhaps it will be useful for people.
It is currently structured as a Gradle module and part of the main repository. It could also be split out into a separate repository (which would align with how the Gradle plugin is maintained).
It uses a blend of Ktor, Kotlin HTML DSL, a dash of HTMX, and some excellent libraries for YAML editing and Kotlin syntax highlighting.
The current initial version is deployed to Fly.io and costs very little to run (so far $0, as the machine suspends when idle and usage below $5 is not billed). It is available at
[...]
, but if we choose to make an official tool, it should probably be something like try.fabrikt.dev.Update: It is now on fabrikt.fly.dev.
Update: The playground supports deeplinking to generation settings which could become useful when debugging an issue. The actual spec is not included in the deeplink, but that's a feature we could add later (would require storing the spec somewhere).
Deeplink example: Models & Micronaut Controllers
I’d love to hear your thoughts on this idea and get feedback on the current version.
I am also completely OK with ditching the idea if you don’t believe it brings value to the project.
What do you think?