Closed SofusA closed 8 months ago
Hey, thanks for your contribution. I wonder if we could we also fix #105 in this PR? I think it would be an easy fix
Also, would it make sense to allow multiple aliases? We could default to vec!["leptos::view", view"]
, but user could add additional aliases through configuration
Hey, thanks for your contribution. I wonder if we could we also fix #105 in this PR? I think it would be an easy fix
Also, would it make sense to allow multiple aliases? We could default to
vec!["leptos::view", view"]
, but user could add additional aliases through configuration
Yeah that would be nice. I will try to give it a shot.
I have pushed new commit which closes #105
looking good, can you add the new configuration setting to the example leptosfmt.toml
in the readme? See: https://github.com/bram209/leptosfmt?tab=readme-ov-file#configuration
The code i pushed yesterday did not work for fully qualified paths since Path::is_ident does not support leading colons.
So i combine the path segments into the full path as a string (view_macro::get_macro_full_path) and use that to compare macro names
I have broken --stdin somehow
looks good to me, thanks!
resolves #17 resolves #105
Closes #17 and to some extend #98
I am quite new to rust and i am not sure this would be the best way to achieve this, since I had to change settings to be references.
You can now override the view macro name in the cli and in settings. This allows for aliasing the macro, or use with plain rstml macro.