@next/eslint-plugin-next 14.2.0-canary.4 → 14.2.0-canary.41

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -22,7 +22,9 @@ function _interop_require_wildcard(obj, nodeInterop) {
22
22
  if (cache && cache.has(obj)) {
23
23
  return cache.get(obj);
24
24
  }
25
- var newObj = {};
25
+ var newObj = {
26
+ __proto__: null
27
+ };
26
28
  var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
27
29
  for(var key in obj){
28
30
  if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
@@ -22,7 +22,9 @@ function _interop_require_wildcard(obj, nodeInterop) {
22
22
  if (cache && cache.has(obj)) {
23
23
  return cache.get(obj);
24
24
  }
25
- var newObj = {};
25
+ var newObj = {
26
+ __proto__: null
27
+ };
26
28
  var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
27
29
  for(var key in obj){
28
30
  if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
@@ -22,7 +22,9 @@ function _interop_require_wildcard(obj, nodeInterop) {
22
22
  if (cache && cache.has(obj)) {
23
23
  return cache.get(obj);
24
24
  }
25
- var newObj = {};
25
+ var newObj = {
26
+ __proto__: null
27
+ };
26
28
  var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
27
29
  for(var key in obj){
28
30
  if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
@@ -33,7 +33,9 @@ function _interop_require_wildcard(obj, nodeInterop) {
33
33
  if (cache && cache.has(obj)) {
34
34
  return cache.get(obj);
35
35
  }
36
- var newObj = {};
36
+ var newObj = {
37
+ __proto__: null
38
+ };
37
39
  var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
38
40
  for(var key in obj){
39
41
  if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
@@ -22,7 +22,9 @@ function _interop_require_wildcard(obj, nodeInterop) {
22
22
  if (cache && cache.has(obj)) {
23
23
  return cache.get(obj);
24
24
  }
25
- var newObj = {};
25
+ var newObj = {
26
+ __proto__: null
27
+ };
26
28
  var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
27
29
  for(var key in obj){
28
30
  if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
@@ -22,7 +22,9 @@ function _interop_require_wildcard(obj, nodeInterop) {
22
22
  if (cache && cache.has(obj)) {
23
23
  return cache.get(obj);
24
24
  }
25
- var newObj = {};
25
+ var newObj = {
26
+ __proto__: null
27
+ };
26
28
  var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
27
29
  for(var key in obj){
28
30
  if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
@@ -88,7 +90,7 @@ module.exports = (0, _definerule.defineRule)({
88
90
  schema: []
89
91
  },
90
92
  create: function create(context) {
91
- var checkTypos = function checkTypos(node, name) {
93
+ function checkTypos(node, name) {
92
94
  if (NEXT_EXPORT_FUNCTIONS.includes(name)) {
93
95
  return;
94
96
  }
@@ -109,7 +111,7 @@ module.exports = (0, _definerule.defineRule)({
109
111
  message: "".concat(name, " may be a typo. Did you mean ").concat(potentialTypos[0].option, "?")
110
112
  });
111
113
  }
112
- };
114
+ }
113
115
  return {
114
116
  ExportNamedDeclaration: function ExportNamedDeclaration(node) {
115
117
  var page = context.getFilename().split("pages", 2)[1];
@@ -101,7 +101,9 @@ module.exports = (0, _definerule.defineRule)({
101
101
  return;
102
102
  }
103
103
  var src = srcNode.value.value;
104
- if (src.startsWith("https://cdn.polyfill.io/v2/") || src.startsWith("https://polyfill.io/v3/")) {
104
+ if (src.startsWith("https://cdn.polyfill.io/v2/") || src.startsWith("https://polyfill.io/v3/") || // https://community.fastly.com/t/new-options-for-polyfill-io-users/2540
105
+ src.startsWith("https://polyfill-fastly.net/") || src.startsWith("https://polyfill-fastly.io/") || // https://blog.cloudflare.com/polyfill-io-now-available-on-cdnjs-reduce-your-supply-chain-risk
106
+ src.startsWith("https://cdnjs.cloudflare.com/polyfill/")) {
105
107
  var featureQueryString = new URL(src).searchParams.get("features");
106
108
  var featuresRequested = (featureQueryString || "").split(",");
107
109
  var unwantedFeatures = featuresRequested.filter(function(feature) {
package/dist/utils/url.js CHANGED
@@ -9,14 +9,14 @@ function _export(target, all) {
9
9
  });
10
10
  }
11
11
  _export(exports, {
12
- normalizeURL: function() {
13
- return normalizeURL;
12
+ execOnce: function() {
13
+ return execOnce;
14
14
  },
15
15
  getUrlFromPagesDirectories: function() {
16
16
  return getUrlFromPagesDirectories;
17
17
  },
18
- execOnce: function() {
19
- return execOnce;
18
+ normalizeURL: function() {
19
+ return normalizeURL;
20
20
  }
21
21
  });
22
22
  var _path = /*#__PURE__*/ _interop_require_wildcard(require("path"));
@@ -50,7 +50,9 @@ function _interop_require_wildcard(obj, nodeInterop) {
50
50
  if (cache && cache.has(obj)) {
51
51
  return cache.get(obj);
52
52
  }
53
- var newObj = {};
53
+ var newObj = {
54
+ __proto__: null
55
+ };
54
56
  var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
55
57
  for(var key in obj){
56
58
  if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@next/eslint-plugin-next",
3
- "version": "14.2.0-canary.4",
3
+ "version": "14.2.0-canary.41",
4
4
  "description": "ESLint plugin for Next.js.",
5
5
  "main": "dist/index.js",
6
6
  "license": "MIT",