filename
stringlengths
20
188
language
stringclasses
3 values
AST-segments
stringlengths
0
204k
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
/** * @author Toru Nagashima <https://github.com/mysticatea> * See LICENSE file in root directory for full license. */ "use strict" const { READ
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
ReferenceTracker } = require("eslint-utils")
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
module.exports = { meta: { docs: { description: "disallow the `Number.MIN_SAFE_INTEGER` property."
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
category: "ES2015"
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
recommended: false
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
url: "http://mysticatea.github.io/eslint-plugin-es/rules/no-number-minsafeinteger.html"
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
}
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
fixable: null
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
messages: { forbidden: "ES2015 '{{name}}' property is forbidden."
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
}
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
schema: []
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
type: "problem"
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
}
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
create(context) { return { "Program:exit"() { const tracker = new ReferenceTracker(context.getScope()) for (const { node
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
path } of tracker.iterateGlobalReferences({ Number: { MIN_SAFE_INTEGER: { [READ]: true }
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
}
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
})) { context.report({ node
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
messageId: "forbidden"
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
data: { name: path.join(".") }
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
}) } }
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
} }
aj07_dveno_node_modules_eslint-plugin-es_lib_rules_no-number-minsafeinteger.js
javascript
}
harshabakku_rainbow-bridge-ETH-XTZ_node_modules_continuation-local-storage_test_async-context.tap.js
javascript
'use strict'; var tap = require('tap')
harshabakku_rainbow-bridge-ETH-XTZ_node_modules_continuation-local-storage_test_async-context.tap.js
javascript
test = tap.test
harshabakku_rainbow-bridge-ETH-XTZ_node_modules_continuation-local-storage_test_async-context.tap.js
javascript
createNamespace = require('../context.js').createNamespace ;
harshabakku_rainbow-bridge-ETH-XTZ_node_modules_continuation-local-storage_test_async-context.tap.js
javascript
test("asynchronously propagating state with local-context-domains"
harshabakku_rainbow-bridge-ETH-XTZ_node_modules_continuation-local-storage_test_async-context.tap.js
javascript
function (t) { t.plan(2); var namespace = createNamespace('namespace'); t.ok(process.namespaces.namespace
harshabakku_rainbow-bridge-ETH-XTZ_node_modules_continuation-local-storage_test_async-context.tap.js
javascript
"namespace has been created"); namespace.run(function () { namespace.set('test'
harshabakku_rainbow-bridge-ETH-XTZ_node_modules_continuation-local-storage_test_async-context.tap.js
javascript
1337); t.equal(namespace.get('test')
harshabakku_rainbow-bridge-ETH-XTZ_node_modules_continuation-local-storage_test_async-context.tap.js
javascript
1337
harshabakku_rainbow-bridge-ETH-XTZ_node_modules_continuation-local-storage_test_async-context.tap.js
javascript
"namespace is working"); }); });
aeither_berry-frontend_frontend_src_components_common.js
javascript
const InflationTimestamp = 1621623768597; const HalflifeDuration = 2628000000;
aeither_berry-frontend_frontend_src_components_common.js
javascript
export const multiplier = () => { const timestamp = new Date().getTime(); const duration = timestamp - InflationTimestamp; return Math.pow(2
aeither_berry-frontend_frontend_src_components_common.js
javascript
duration / HalflifeDuration); }
aj07_dveno_node_modules_object.getownpropertydescriptors_index.js
javascript
'use strict'; var define = require('define-properties'); var implementation = require('./implementation'); var getPolyfill = require('./polyfill'); var shim = require('./shim');
aj07_dveno_node_modules_object.getownpropertydescriptors_index.js
javascript
define(implementation
aj07_dveno_node_modules_object.getownpropertydescriptors_index.js
javascript
{ getPolyfill: getPolyfill
aj07_dveno_node_modules_object.getownpropertydescriptors_index.js
javascript
implementation: implementation
aj07_dveno_node_modules_object.getownpropertydescriptors_index.js
javascript
shim: shim }); module.exports = implementation;
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
/** * Interactions used by the Site Health modules in WordPress. * * @output wp-admin/js/site-health.js */ /* global ajaxurl
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
ClipboardJS
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
SiteHealth
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
wp */
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
jQuery( document ).ready( function( $ ) { var __ = wp.i18n.__
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
_n = wp.i18n._n
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
sprintf = wp.i18n.sprintf; var data; var clipboard = new ClipboardJS( '.site-health-copy-buttons .copy-button' ); var isDebugTab = $( '.health-check-body.health-check-debug-tab' ).length; var pathsSizesSection = $( '#health-check-accordion-block-wp-paths-sizes' ); // Debug information copy section. clipboard.on( 'success'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
function( e ) { var $wrapper = $( e.trigger ).closest( 'div' ); $( '.success'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
$wrapper ).addClass( 'visible' ); wp.a11y.speak( __( 'Site information has been added to your clipboard.' ) ); } ); // Accordion handling in various areas. $( '.health-check-accordion' ).on( 'click'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'.health-check-accordion-trigger'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
function() { var isExpanded = ( 'true' === $( this ).attr( 'aria-expanded' ) ); if ( isExpanded ) { $( this ).attr( 'aria-expanded'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'false' ); $( '#' + $( this ).attr( 'aria-controls' ) ).attr( 'hidden'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
true ); } else { $( this ).attr( 'aria-expanded'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'true' ); $( '#' + $( this ).attr( 'aria-controls' ) ).attr( 'hidden'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
false ); } } ); // Site Health test handling. $( '.site-health-view-passed' ).on( 'click'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
function() { var goodIssuesWrapper = $( '#health-check-issues-good' ); goodIssuesWrapper.toggleClass( 'hidden' ); $( this ).attr( 'aria-expanded'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
! goodIssuesWrapper.hasClass( 'hidden' ) ); } ); /** * Append a new issue to the issue list. * * @since 5.2.0 * * @param {Object} issue The issue data. */ function AppendIssue( issue ) { var template = wp.template( 'health-check-issue' )
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
issueWrapper = $( '#health-check-issues-' + issue.status )
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
heading
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
count; SiteHealth.site_status.issues[ issue.status ]++; count = SiteHealth.site_status.issues[ issue.status ]; if ( 'critical' === issue.status ) { heading = sprintf( _n( '%s critical issue'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'%s critical issues'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
count )
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'<span class="issue-count">' + count + '</span>' ); } else if ( 'recommended' === issue.status ) { heading = sprintf( _n( '%s recommended improvement'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'%s recommended improvements'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
count )
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'<span class="issue-count">' + count + '</span>' ); } else if ( 'good' === issue.status ) { heading = sprintf( _n( '%s item with no issues detected'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'%s items with no issues detected'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
count )
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'<span class="issue-count">' + count + '</span>' ); } if ( heading ) { $( '.site-health-issue-count-title'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
issueWrapper ).html( heading ); } $( '.issues'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'#health-check-issues-' + issue.status ).append( template( issue ) ); } /** * Update site health status indicator as asynchronous tests are run and returned. * * @since 5.2.0 */ function RecalculateProgression() { var r
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
c
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
pct; var $progress = $( '.site-health-progress' ); var $wrapper = $progress.closest( '.site-health-progress-wrapper' ); var $progressLabel = $( '.site-health-progress-label'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
$wrapper ); var $circle = $( '.site-health-progress svg #bar' ); var totalTests = parseInt( SiteHealth.site_status.issues.good
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
0 ) + parseInt( SiteHealth.site_status.issues.recommended
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
0 ) + ( parseInt( SiteHealth.site_status.issues.critical
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
0 ) * 1.5 ); var failedTests = ( parseInt( SiteHealth.site_status.issues.recommended
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
0 ) * 0.5 ) + ( parseInt( SiteHealth.site_status.issues.critical
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
0 ) * 1.5 ); var val = 100 - Math.ceil( ( failedTests / totalTests ) * 100 ); if ( 0 === totalTests ) { $progress.addClass( 'hidden' ); return; } $wrapper.removeClass( 'loading' ); r = $circle.attr( 'r' ); c = Math.PI * ( r * 2 ); if ( 0 > val ) { val = 0; } if ( 100 < val ) { val = 100; } pct = ( ( 100 - val ) / 100 ) * c; $circle.css( { strokeDashoffset: pct } ); if ( 1 > parseInt( SiteHealth.site_status.issues.critical
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
0 ) ) { $( '#health-check-issues-critical' ).addClass( 'hidden' ); } if ( 1 > parseInt( SiteHealth.site_status.issues.recommended
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
0 ) ) { $( '#health-check-issues-recommended' ).addClass( 'hidden' ); } if ( 80 <= val && 0 === parseInt( SiteHealth.site_status.issues.critical
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
0 ) ) { $wrapper.addClass( 'green' ).removeClass( 'orange' ); $progressLabel.text( __( 'Good' ) ); wp.a11y.speak( __( 'All site health tests have finished running. Your site is looking good
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
and the results are now available on the page.' ) ); } else { $wrapper.addClass( 'orange' ).removeClass( 'green' ); $progressLabel.text( __( 'Should be improved' ) ); wp.a11y.speak( __( 'All site health tests have finished running. There are items that should be addressed
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
and the results are now available on the page.' ) ); } if ( ! isDebugTab ) { $.post( ajaxurl
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
{ 'action': 'health-check-site-status-result'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'_wpnonce': SiteHealth.nonce.site_status_result
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'counts': SiteHealth.site_status.issues } ); if ( 100 === val ) { $( '.site-status-all-clear' ).removeClass( 'hide' ); $( '.site-status-has-issues' ).addClass( 'hide' ); } } } /** * Queue the next asynchronous test when we're ready to run it. * * @since 5.2.0 */ function maybeRunNextAsyncTest() { var doCalculation = true; if ( 1 <= SiteHealth.site_status.async.length ) { $.each( SiteHealth.site_status.async
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
function() { var data = { 'action': 'health-check-' + this.test.replace( '_'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'-' )
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'_wpnonce': SiteHealth.nonce.site_status }; if ( this.completed ) { return true; } doCalculation = false; this.completed = true; $.post( ajaxurl
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
data
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
function( response ) { /** This filter is documented in wp-admin/includes/class-wp-site-health.php */ AppendIssue( wp.hooks.applyFilters( 'site_status_test_result'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
response.data ) ); maybeRunNextAsyncTest(); } ); return false; } ); } if ( doCalculation ) { RecalculateProgression(); } } if ( 'undefined' !== typeof SiteHealth && ! isDebugTab ) { if ( 0 === SiteHealth.site_status.direct.length && 0 === SiteHealth.site_status.async.length ) { RecalculateProgression(); } else { SiteHealth.site_status.issues = { 'good': 0
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'recommended': 0
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'critical': 0 }; } if ( 0 < SiteHealth.site_status.direct.length ) { $.each( SiteHealth.site_status.direct
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
function() { AppendIssue( this ); } ); } if ( 0 < SiteHealth.site_status.async.length ) { data = { 'action': 'health-check-' + SiteHealth.site_status.async[0].test.replace( '_'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'-' )
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
'_wpnonce': SiteHealth.nonce.site_status }; SiteHealth.site_status.async[0].completed = true; $.post( ajaxurl
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
data
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
function( response ) { AppendIssue( response.data ); maybeRunNextAsyncTest(); } ); } else { RecalculateProgression(); } } function getDirectorySizes() { var data = { action: 'health-check-get-sizes'
Peersyst_woocommerce-gateway-wax_docker_wordpress_data_wp-admin_js_site-health.js
javascript
_wpnonce: SiteHealth.nonce.site_status_result }; var timestamp = ( new Date().getTime() ); // After 3 seconds announce that we're still waiting for directory sizes. var timeout = window.setTimeout( function() { wp.a11y.speak( __( 'Please wait...' ) ); }