You are trying to load server inner path in the url, you need to use plugin_dir_url instead of plugin_dir_path
define('APV_PLUGIN_DIR', plugin_dir_url(__FILE__)); define('BUILD_DIR', APV_PLUGIN_DIR . 'build/');