...
- Click on Global Libraries, select <FLEXJS_INSTALL_FOLDER>/frameworks/libs. Then, deselect "air" and "player\23.0" in my case.
- In the next step IntelliJ will ask for choose project where library should be added
...
- Click on Modules, select the module you want to configure and click on Dependencies.
- Select the FlexJS SDK you just added.
- Add the FlexJS global library you just added too, if you have not added it in the previous steps.
- Click on Compiler Options
- Click on Module Defaults (If you have more than one module, it makes sense you apply this and the following to Project Defaults instead).
- Remove the default en_US local
- In Default options for modules, add: -load-config+=<FLEXJS_INSTALL_FOLDER>/ide/IDEA/intellij-config.xml
- Click OK to validate.
- In Additional compiler options, add: -targets=JSFlex,SWF -external-library-path+=<FLEX_JS_INSTALL_FOLDER>/js/libs/js.swc -allow-subclass-overrides=true
(The -targets=JSFlex,SWF will tell the compiler to build both the SWF / SWC and the JS version of your module. If you want to build the JS only, use -targets=JSFlex) - Click OK to validate.
You should be able to build your project now, click on Build -> Rebuild project. (Fix the eventual error the compiler found and use Build -> Make project)
...