Skip to content
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

Upstream generators #158

Merged
merged 11 commits into from
Nov 27, 2024
Merged

Upstream generators #158

merged 11 commits into from
Nov 27, 2024

Conversation

skryukov
Copy link
Contributor

@skryukov skryukov commented Nov 11, 2024

This PR upstreams generators from https://github.com/skryukov/inertia_rails-contrib

TODO:

  • add TypeScript scaffolds for React
  • add TypeScript scaffolds for Svelte 4
  • add TypeScript scaffolds for Svelte 5
  • add TypeScript scaffolds for Vue
  • add smoke tests
  • setup typechecks and run them in smoke tests
  • check react and svelte ts hacks

@jacobmichels
Copy link

This is amazing, I'd really like to use the typescript scaffolds you've created. Do you need any assistance in getting this PR ready for review?

@skryukov
Copy link
Contributor Author

skryukov commented Nov 19, 2024

@jacobmichels thanks for the ping! I hope to finish this PR in couple days, my current goal is to implement a simple smoke test that will generate new Rails app, install inertia, generate some scaffolds and run system tests.

@skryukov skryukov force-pushed the upstream-generators branch 17 times, most recently from 4a4982c to d6638ef Compare November 22, 2024 18:26
@skryukov skryukov force-pushed the upstream-generators branch from d6638ef to 6cff2e8 Compare November 22, 2024 19:14
@skryukov skryukov force-pushed the upstream-generators branch from 52cba68 to 189ffb6 Compare November 23, 2024 07:00
@skryukov skryukov marked this pull request as ready for review November 23, 2024 07:12
module Generators
class JSPackageManager
def self.package_managers
%w[npm yarn bun pnpm]
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gonna point to this file next time I need an example of why the JS ecosystem feels like the wild west compared to Ruby 😅

module Generators
module Helper
class << self
def guess_the_default_framework
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what a method name!

require_relative '../../../lib/generators/inertia/install/install_generator'
require 'generator_spec'

RSpec.describe Inertia::Generators::InstallGenerator, type: :generator do
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is really cool!

Copy link
Collaborator

@bknoles bknoles left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so excited to have this upstreamed! thanks @skryukov

@bknoles bknoles merged commit 8170a37 into inertiajs:master Nov 27, 2024
52 checks passed
@skryukov skryukov deleted the upstream-generators branch November 27, 2024 20:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants