docs: public static <T> T getTypedProperty(Scriptable s, String name, Class<T> type) {
          Object val = getProperty(s, name);
          if(val == Scriptable.NOT_FOUND) {
              val = null;
          }
          return type.cast(Context.jsToJava(val, type));
      }