How can I create a widgetstyle (Customized slate) class in "/Style" folder in shooterGame?

Can not Create a widget style(Customized slate) class in "/Style"folder in shooterGame

if i use add a code in editor the script will appear under Source/ShooterGame folder, if i move the .cpp & .h file into /Style folder , it will gives me lots of errors

What is the right way to Create a customized slate widget Style?

If that’s source code, it still has to exist somewhere within the Source folder for your game.

If you take a look at the ShooterGame sample, you can see that the classes defining the custom Slate widget styles exist inside ShooterGame\Source\ShooterGame\Private\UI\Style, but the uasset files that define an instance of that widget style exist within ShooterGame\Content\UI\Styles.

ShooterMenuStyleWidgetStyle.h/.cpp should provide a reasonable example of setting up a custom Slate widget style class. With your class created, you can make an instance of it via the Content Browser (New → Miscellaneous → Slate Widget Style).

lol !!! just needs to set the path in modulerule first
PrivateIncludePaths.AddRange add path here