Script loading issues#

Can't add script component 'Foo' because the script class cannot be found.
Make sure that there are no compiler errors and the file name and class name match.
'Foo' is missing the class attribute 'ExtensionOfNativeClass'!

Troubleshooting steps#

Make sure your script is saved, then follow these steps:

  1. Class and file names
  2. Console errors
  3. Checking inheritance
  4. Editor contexts
    1. Editor folders
    2. Editor Assembly Definitions
  5. Restart Unity
  6. Project reimport