text stringlengths 1 2.83M | id stringlengths 16 152 | metadata dict | __index_level_0__ int64 0 949 |
|---|---|---|---|
import { expect } from 'chai';
import { stubMethod } from 'hanbi';
import { createTestServer, expectIncludes } from '@web/dev-server-core/test-helpers';
import { Browser, HTTPResponse, launch as launchPuppeteer, Page } from 'puppeteer';
import { posix as pathUtil } from 'path';
import { hmrPlugin } from '../src/index.... | modernweb-dev/web/packages/dev-server-hmr/test/browser.test.ts/0 | {
"file_path": "modernweb-dev/web/packages/dev-server-hmr/test/browser.test.ts",
"repo_id": "modernweb-dev",
"token_count": 3078
} | 183 |
import { spy } from 'hanbi';
export const __postDataSpy = spy();
__postDataSpy.returns(Promise.resolve());
export const postData = __postDataSpy.handler;
export const __importMeta = import.meta;
| modernweb-dev/web/packages/dev-server-import-maps/test-browser/test/mocks/postData.js/0 | {
"file_path": "modernweb-dev/web/packages/dev-server-import-maps/test-browser/test/mocks/postData.js",
"repo_id": "modernweb-dev",
"token_count": 66
} | 184 |
import { isUri } from 'valid-url';
import { Document as DocumentAst, Node as NodeAst } from 'parse5';
import { queryAll, predicates, getAttribute, hasAttribute } from '@web/dev-server-core/dist/dom5';
function isDeferred(script: NodeAst) {
return getAttribute(script, 'type') === 'module' || hasAttribute(script, 'def... | modernweb-dev/web/packages/dev-server-legacy/src/findJsScripts.ts/0 | {
"file_path": "modernweb-dev/web/packages/dev-server-legacy/src/findJsScripts.ts",
"repo_id": "modernweb-dev",
"token_count": 495
} | 185 |
# Dev Server Rollup
Adapter for using rollup plugins in Web Dev Server and Web Test Runner.
See [our website](https://modern-web.dev/docs/dev-server/plugins/rollup/) for full documentation.
| modernweb-dev/web/packages/dev-server-rollup/README.md/0 | {
"file_path": "modernweb-dev/web/packages/dev-server-rollup/README.md",
"repo_id": "modernweb-dev",
"token_count": 53
} | 186 |
export default 'moduleA';
| modernweb-dev/web/packages/dev-server-rollup/test/node/fixtures/basic/node_modules/module-a/index.js/0 | {
"file_path": "modernweb-dev/web/packages/dev-server-rollup/test/node/fixtures/basic/node_modules/module-a/index.js",
"repo_id": "modernweb-dev",
"token_count": 7
} | 187 |
module.exports = 'foo';
| modernweb-dev/web/packages/dev-server-rollup/test/node/fixtures/commonjs/modules/default-export.js/0 | {
"file_path": "modernweb-dev/web/packages/dev-server-rollup/test/node/fixtures/commonjs/modules/default-export.js",
"repo_id": "modernweb-dev",
"token_count": 9
} | 188 |
import moduleA from 'module-a';
import moduleB from 'resolve-outside-dir-foo';
console.log(moduleA);
console.log(moduleB);
| modernweb-dev/web/packages/dev-server-rollup/test/node/fixtures/resolve-outside-dir/src/app.js/0 | {
"file_path": "modernweb-dev/web/packages/dev-server-rollup/test/node/fixtures/resolve-outside-dir/src/app.js",
"repo_id": "modernweb-dev",
"token_count": 42
} | 189 |
# Dev Server Storybook
Plugin to use [storybook](https://github.com/storybookjs/storybook) with Web Dev Server.
See [our website](https://modern-web.dev/docs/dev-server/plugins/storybook/) for full documentation.
| modernweb-dev/web/packages/dev-server-storybook/README.md/0 | {
"file_path": "modernweb-dev/web/packages/dev-server-storybook/README.md",
"repo_id": "modernweb-dev",
"token_count": 63
} | 190 |
import { storybookPlugin } from '../../index.mjs';
export default {
rootDir: '../..',
open: true,
nodeResolve: true,
plugins: [
storybookPlugin({
type: 'web-components',
configDir: 'demo/wc/.storybook',
}),
],
};
| modernweb-dev/web/packages/dev-server-storybook/demo/wc/web-dev-server.config.mjs/0 | {
"file_path": "modernweb-dev/web/packages/dev-server-storybook/demo/wc/web-dev-server.config.mjs",
"repo_id": "modernweb-dev",
"token_count": 101
} | 191 |
import fs from 'fs';
import { StorybookConfig } from '../config/StorybookConfig.js';
import { createBrowserImport } from '../utils.js';
function createManagerImport(rootDir: string, managerJsPath: string) {
if (!fs.existsSync(managerJsPath)) {
return '';
}
const managerImport = createBrowserImport(rootDir, m... | modernweb-dev/web/packages/dev-server-storybook/src/shared/html/createManagerHtml.ts/0 | {
"file_path": "modernweb-dev/web/packages/dev-server-storybook/src/shared/html/createManagerHtml.ts",
"repo_id": "modernweb-dev",
"token_count": 563
} | 192 |
<html>
<body>
<img width="100" src="../logo.png" />
<h1>Node resolve demo</h1>
<p>A demo which resolves bare module imports</p>
<div id="test"></div>
<script type="module">
// inline bare modules are resolved
import { render, html } from 'lit-html';
window.__inlineNodeResolve... | modernweb-dev/web/packages/dev-server/demo/export-conditions/index.html/0 | {
"file_path": "modernweb-dev/web/packages/dev-server/demo/export-conditions/index.html",
"repo_id": "modernweb-dev",
"token_count": 324
} | 193 |
import { html, render } from 'lit-html';
import { LitElement } from 'lit-element';
class MyElement extends LitElement {
connectedCallback() {
super.connectedCallback();
render(html` <p>Web component instantiated ✓</p> `, document.getElementById('web-component'));
}
render() {
return html` <p>Elemen... | modernweb-dev/web/packages/dev-server/demo/node-resolve/module.js/0 | {
"file_path": "modernweb-dev/web/packages/dev-server/demo/node-resolve/module.js",
"repo_id": "modernweb-dev",
"token_count": 149
} | 194 |
const foo = { a: 1 };
const bar = { ...foo };
const objectSpread = bar.a === 1;
async function asyncFunction() {}
const asyncFunctions = asyncFunction() instanceof Promise;
const exponentation = 2 ** 4 === 16;
class Foo {
constructor() {
this.foo = 'bar';
}
}
const classes = new Foo().foo === 'bar';
const t... | modernweb-dev/web/packages/dev-server/demo/syntax/stage-4-features.js/0 | {
"file_path": "modernweb-dev/web/packages/dev-server/demo/syntax/stage-4-features.js",
"repo_id": "modernweb-dev",
"token_count": 257
} | 195 |
function requirePlugin() {
try {
const path = require.resolve('@web/dev-server-esbuild', { paths: [__dirname, process.cwd()] });
return require(path);
} catch (error) {
if ((error as NodeJS.ErrnoException).code === 'MODULE_NOT_FOUND') {
throw new Error(
'You need to add @web/dev-server-esb... | modernweb-dev/web/packages/dev-server/src/plugins/esbuildPlugin.ts/0 | {
"file_path": "modernweb-dev/web/packages/dev-server/src/plugins/esbuildPlugin.ts",
"repo_id": "modernweb-dev",
"token_count": 210
} | 196 |
{
"name": "@web/mocks",
"version": "1.1.1",
"publishConfig": {
"access": "public"
},
"description": "MSW integration for @web tooling",
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/modernweb-dev/web.git",
"directory": "packages/mocks"
},
"author": "modern... | modernweb-dev/web/packages/mocks/package.json/0 | {
"file_path": "modernweb-dev/web/packages/mocks/package.json",
"repo_id": "modernweb-dev",
"token_count": 1115
} | 197 |
# @web/parse5-utils
## 2.1.0
### Minor Changes
- c185cbaa: Set minimum node version to 18
## 2.0.2
### Patch Changes
- 640ba85f: added types for main entry point
## 2.0.1
### Patch Changes
- d5da0e4a: Adds support for traversing <template> elements
## 2.0.0
### Major Changes
- febd9d9d: Set node 16 as the m... | modernweb-dev/web/packages/parse5-utils/CHANGELOG.md/0 | {
"file_path": "modernweb-dev/web/packages/parse5-utils/CHANGELOG.md",
"repo_id": "modernweb-dev",
"token_count": 390
} | 198 |
import { Document, Node, ParentNode, parse, serialize } from 'parse5';
import {
findElements,
getAttribute,
createScript,
getTextContent,
insertBefore,
appendChild,
createElement,
findElement,
getTagName,
Element,
} from '@web/parse5-utils';
import { PolyfillsLoaderConfig, PolyfillsLoader, Generate... | modernweb-dev/web/packages/polyfills-loader/src/injectPolyfillsLoader.ts/0 | {
"file_path": "modernweb-dev/web/packages/polyfills-loader/src/injectPolyfillsLoader.ts",
"repo_id": "modernweb-dev",
"token_count": 1337
} | 199 |
const html = require('../../dist/index').default;
module.exports = {
output: {
dir: './demo/dist',
},
plugins: [
html({
input: '**/*.html',
flattenOutput: false,
rootDir: __dirname,
}),
],
};
| modernweb-dev/web/packages/rollup-plugin-html/demo/mpa/rollup.config.js/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-html/demo/mpa/rollup.config.js",
"repo_id": "modernweb-dev",
"token_count": 104
} | 200 |
import { Document, serialize } from 'parse5';
import fs from 'fs';
import path from 'path';
import { InputAsset } from '../InputData.js';
import {
findAssets,
getSourcePaths,
isHashedAsset,
resolveAssetFilePath,
createAssetPicomatchMatcher,
} from '../../assets/utils.js';
export interface ExtractAssetsParams... | modernweb-dev/web/packages/rollup-plugin-html/src/input/extract/extractAssets.ts/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-html/src/input/extract/extractAssets.ts",
"repo_id": "modernweb-dev",
"token_count": 644
} | 201 |
import { ScriptModuleTag } from './RollupPluginHTMLOptions.js';
const PLUGIN = '[@web/rollup-plugin-html]';
export const NOOP_IMPORT: ScriptModuleTag = { importPath: '@web/rollup-plugin-html-noop' };
export function createError(msg: string) {
return new Error(`${PLUGIN} ${msg}`);
}
| modernweb-dev/web/packages/rollup-plugin-html/src/utils.ts/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-html/src/utils.ts",
"repo_id": "modernweb-dev",
"token_count": 101
} | 202 |
f | modernweb-dev/web/packages/rollup-plugin-html/test/fixtures/resolves-assets-in-styles-images/images/star.svg/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-html/test/fixtures/resolves-assets-in-styles-images/images/star.svg",
"repo_id": "modernweb-dev",
"token_count": 1
} | 203 |
<a href="assets/docs/partial.html"></a>
| modernweb-dev/web/packages/rollup-plugin-html/test/fixtures/rollup-plugin-html/exclude/index.html/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-html/test/fixtures/rollup-plugin-html/exclude/index.html",
"repo_id": "modernweb-dev",
"token_count": 15
} | 204 |
export default 'shared';
| modernweb-dev/web/packages/rollup-plugin-html/test/fixtures/rollup-plugin-html/pages/shared.js/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-html/test/fixtures/rollup-plugin-html/pages/shared.js",
"repo_id": "modernweb-dev",
"token_count": 6
} | 205 |
import cjsEntrypoint from './src/rollup-plugin-import-meta-assets.js';
const { importMetaAssets } = cjsEntrypoint;
export { importMetaAssets };
| modernweb-dev/web/packages/rollup-plugin-import-meta-assets/index.mjs/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-import-meta-assets/index.mjs",
"repo_id": "modernweb-dev",
"token_count": 48
} | 206 |
export const nameOne = 'one-name';
export const imageOne = new URL('../one.svg', import.meta.url).href;
| modernweb-dev/web/packages/rollup-plugin-import-meta-assets/test/fixtures/one/one.js/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-import-meta-assets/test/fixtures/one/one.js",
"repo_id": "modernweb-dev",
"token_count": 34
} | 207 |
function __variableDynamicURLRuntime0__(path) {
switch (path) {
case './dynamic-assets/one.svg': return new URL(new URL('assets/one-ZInu4dBJ.svg', import.meta.url).href, import.meta.url);
case './dynamic-assets/three.svg': return new URL(new URL('assets/three-CDdgprDC.svg', import.meta.url).href, import.meta.... | modernweb-dev/web/packages/rollup-plugin-import-meta-assets/test/snapshots/dynamic-vars.js/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-import-meta-assets/test/snapshots/dynamic-vars.js",
"repo_id": "modernweb-dev",
"token_count": 439
} | 208 |
const nameTwo = 'two-name';
const imageTwo = new URL('../../two.svg', import.meta.url).href;
export { imageTwo, nameTwo };
| modernweb-dev/web/packages/rollup-plugin-import-meta-assets/test/snapshots/two-bundle.js/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-import-meta-assets/test/snapshots/two-bundle.js",
"repo_id": "modernweb-dev",
"token_count": 43
} | 209 |
<script type="module" src="../entrypoint-a.js"></script>
<script type="module" src="../entrypoint-b.js"></script> | modernweb-dev/web/packages/rollup-plugin-polyfills-loader/test/fixtures/non-flat/index.html/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-polyfills-loader/test/fixtures/non-flat/index.html",
"repo_id": "modernweb-dev",
"token_count": 37
} | 210 |
/* eslint-disable no-await-in-loop */
import { OutputChunk, rollup, OutputAsset, RollupOptions, OutputOptions } from 'rollup';
import { expect } from 'chai';
import fs from 'fs';
import path from 'path';
import { rollupPluginHTML as html } from '@web/rollup-plugin-html';
import polyfillsLoader from '../../src/index.js'... | modernweb-dev/web/packages/rollup-plugin-polyfills-loader/test/src/rollupPluginPolyfillsLoader.test.ts/0 | {
"file_path": "modernweb-dev/web/packages/rollup-plugin-polyfills-loader/test/src/rollupPluginPolyfillsLoader.test.ts",
"repo_id": "modernweb-dev",
"token_count": 4833
} | 211 |
# @web/storybook-builder
See [our website](https://modern-web.dev/docs/storybook-builder/overview/) for full documentation.
| modernweb-dev/web/packages/storybook-builder/README.md/0 | {
"file_path": "modernweb-dev/web/packages/storybook-builder/README.md",
"repo_id": "modernweb-dev",
"token_count": 38
} | 212 |
// must be valid names (without \0) to let the transform logic work, specifically "rollup-plugin-external-globals"
// must have extension, otherwise "fromRollup" adapter will resolve it incorrectly as an "outside of root" dir
const PREFIX = 'virtual-web-storybook-builder-';
export const virtualAppFilename = `${PREFIX}a... | modernweb-dev/web/packages/storybook-builder/src/virtual-file-names.ts/0 | {
"file_path": "modernweb-dev/web/packages/storybook-builder/src/virtual-file-names.ts",
"repo_id": "modernweb-dev",
"token_count": 131
} | 213 |
import type { PresetProperty } from '@storybook/types';
import type { StorybookConfig } from './types.js';
export const core: PresetProperty<'core', StorybookConfig> = {
builder: '@web/storybook-builder',
renderer: '@storybook/web-components',
};
| modernweb-dev/web/packages/storybook-framework-web-components/src/preset.ts/0 | {
"file_path": "modernweb-dev/web/packages/storybook-framework-web-components/src/preset.ts",
"repo_id": "modernweb-dev",
"token_count": 80
} | 214 |
# Web Test Runner Browserstack
Browser launchers for web test runner to run tests remotely on [Browserstack](https://www.browserstack.com/).
See [our website](https://modern-web.dev/docs/test-runner/browser-launchers/browserstack/) for full documentation.
| modernweb-dev/web/packages/test-runner-browserstack/README.md/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-browserstack/README.md",
"repo_id": "modernweb-dev",
"token_count": 67
} | 215 |
import * as puppeteerCore from 'puppeteer-core';
import { ChromeLauncher, CreateBrowserContextFn, CreatePageFn } from './ChromeLauncher.js';
import { PuppeteerNodeLaunchOptions } from 'puppeteer-core';
export interface ChromeLauncherArgs {
puppeteer?: typeof puppeteerCore;
launchOptions?: PuppeteerNodeLaunchOption... | modernweb-dev/web/packages/test-runner-chrome/src/index.ts/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-chrome/src/index.ts",
"repo_id": "modernweb-dev",
"token_count": 278
} | 216 |
/* eslint-env browser, es2020 */
const PARAM_SESSION_ID = 'wtr-session-id';
const sessionId = new URL(window.location.href).searchParams.get(PARAM_SESSION_ID);
function isObject(payload) {
return payload != null && typeof payload === 'object';
}
export async function executeServerCommand(command, payload, pluginNa... | modernweb-dev/web/packages/test-runner-commands/browser/commands.mjs/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-commands/browser/commands.mjs",
"repo_id": "modernweb-dev",
"token_count": 2087
} | 217 |
import path from 'path';
import { runTests } from '@web/test-runner-core/test-helpers';
import { chromeLauncher } from '@web/test-runner-chrome';
import { playwrightLauncher } from '@web/test-runner-playwright';
import { a11ySnapshotPlugin } from '../../src/a11ySnapshotPlugin.js';
describe('a11ySnapshotPlugin', funct... | modernweb-dev/web/packages/test-runner-commands/test/a11y-snapshot/a11ySnapshotPlugin.test.ts/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-commands/test/a11y-snapshot/a11ySnapshotPlugin.test.ts",
"repo_id": "modernweb-dev",
"token_count": 374
} | 218 |
import { sendKeys } from '../../browser/commands.mjs';
import { expect } from '../chai.js';
it('natively types into an input', async () => {
const keys = 'abc123';
const input = document.createElement('input');
document.body.append(input);
input.focus();
await sendKeys({
type: keys,
});
expect(inpu... | modernweb-dev/web/packages/test-runner-commands/test/send-keys/browser-test.js/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-commands/test/send-keys/browser-test.js",
"repo_id": "modernweb-dev",
"token_count": 668
} | 219 |
# Test Runner Core
## Projects
- `@web/test-runner-core` implements the basics of the test runner.
- `@web/test-runner` reads command line args, starts the test runner, and adds default opinionated plugins, test framework and reporter.
- `@web/dev-server-core` is used as web server in the test runner.
- `@web/config-... | modernweb-dev/web/packages/test-runner-core/architecture.md/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-core/architecture.md",
"repo_id": "modernweb-dev",
"token_count": 2523
} | 220 |
import { BrowserLauncher } from '../browser-launcher/BrowserLauncher';
import { TestRunnerCoreConfig } from './TestRunnerCoreConfig.js';
export interface TestRunnerGroupConfig {
name: string;
configFilePath?: string;
files?: string | string[];
browsers?: BrowserLauncher[];
testRunnerHtml?: (
testRunnerIm... | modernweb-dev/web/packages/test-runner-core/src/config/TestRunnerGroupConfig.ts/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-core/src/config/TestRunnerGroupConfig.ts",
"repo_id": "modernweb-dev",
"token_count": 126
} | 221 |
import path from 'path';
import { SourceMapConverter } from 'convert-source-map';
import { SourceMapConsumer } from 'source-map';
import { fetchSourceMap } from '../../../utils/fetchSourceMap.js';
import { StackLocation } from '@web/browser-logs';
export type SourceMapFunction = (
loc: StackLocation,
userAgent: s... | modernweb-dev/web/packages/test-runner-core/src/server/plugins/api/createSourceMapFunction.ts/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-core/src/server/plugins/api/createSourceMapFunction.ts",
"repo_id": "modernweb-dev",
"token_count": 1282
} | 222 |
export type TestSessionStatus = 'SCHEDULED' | 'INITIALIZING' | 'STARTED' | 'FINISHED';
export const SESSION_STATUS = {
// waiting for a browser to free up and run this test session
SCHEDULED: 'SCHEDULED' as TestSessionStatus,
// browser is booting up, waiting to ping back that it's starting
INITIALIZING: 'INI... | modernweb-dev/web/packages/test-runner-core/src/test-session/TestSessionStatus.ts/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-core/src/test-session/TestSessionStatus.ts",
"repo_id": "modernweb-dev",
"token_count": 221
} | 223 |
{
"name": "@web/test-runner-junit-reporter",
"version": "0.7.1",
"publishConfig": {
"access": "public"
},
"description": "Junit reporter for @web/test-runner",
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/modernweb-dev/web.git",
"directory": "packages/test-ru... | modernweb-dev/web/packages/test-runner-junit-reporter/package.json/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-junit-reporter/package.json",
"repo_id": "modernweb-dev",
"token_count": 635
} | 224 |
import deepmerge from 'deepmerge';
import createConfig from '../../rollup.browser.config.mjs';
const REGEXP_DTS_MOCHA = /'..\/..\/..\/node_modules\/mocha\/mocha.js'/g;
const REGEXP_DTS_CORE = /'..\/..\/test-runner-core\/browser\/session.js'/g;
const rewriteDtsPlugin = {
generateBundle(options, bundle) {
for (co... | modernweb-dev/web/packages/test-runner-mocha/rollup.config.mjs/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-mocha/rollup.config.mjs",
"repo_id": "modernweb-dev",
"token_count": 675
} | 225 |
{
"name": "@web/test-runner-module-mocking",
"version": "0.1.0",
"publishConfig": {
"access": "public"
},
"description": "Package to enable mocking modules in @web/test-runner",
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/modernweb-dev/web.git",
"directory":... | modernweb-dev/web/packages/test-runner-module-mocking/package.json/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-module-mocking/package.json",
"repo_id": "modernweb-dev",
"token_count": 618
} | 226 |
import path from 'path';
import { fileURLToPath } from 'url';
import { runTests } from '@web/test-runner-core/test-helpers';
import { chromeLauncher } from '@web/test-runner-chrome';
import { nodeResolvePlugin } from '@web/dev-server';
import { moduleMockingPlugin } from '../src/moduleMockingPlugin.js';
import { expec... | modernweb-dev/web/packages/test-runner-module-mocking/test/moduleMockingPlugin.test.ts/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-module-mocking/test/moduleMockingPlugin.test.ts",
"repo_id": "modernweb-dev",
"token_count": 1303
} | 227 |
// this file is autogenerated with the generate-mjs-dts-entrypoints script
import cjsEntrypoint from './dist/index.js';
const { seleniumLauncher, SeleniumLauncher } = cjsEntrypoint;
export { seleniumLauncher, SeleniumLauncher };
| modernweb-dev/web/packages/test-runner-selenium/index.mjs/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-selenium/index.mjs",
"repo_id": "modernweb-dev",
"token_count": 73
} | 228 |
export default 'moduleFeaturesA';
| modernweb-dev/web/packages/test-runner-selenium/test/fixtures/module-features-a.js/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-selenium/test/fixtures/module-features-a.js",
"repo_id": "modernweb-dev",
"token_count": 8
} | 229 |
# @web/test-runner-webdriver
## 0.8.0
### Minor Changes
- c185cbaa: Set minimum node version to 18
### Patch Changes
- Updated dependencies [c185cbaa]
- @web/test-runner-core@0.13.0
## 0.7.2
### Patch Changes
- Updated dependencies [43be7391]
- @web/test-runner-core@0.12.0
## 0.7.1
### Patch Changes
- 64... | modernweb-dev/web/packages/test-runner-webdriver/CHANGELOG.md/0 | {
"file_path": "modernweb-dev/web/packages/test-runner-webdriver/CHANGELOG.md",
"repo_id": "modernweb-dev",
"token_count": 1037
} | 230 |
import { expect } from '@esm-bundle/chai';
import { foo } from '../src/foo.js';
it('works', () => {
foo();
expect(true).to.be.true;
});
| modernweb-dev/web/packages/test-runner/demo/coverage-babel/test/a.test.js/0 | {
"file_path": "modernweb-dev/web/packages/test-runner/demo/coverage-babel/test/a.test.js",
"repo_id": "modernweb-dev",
"token_count": 57
} | 231 |
export { a } from './a.js';
export { b } from './b.js'; | modernweb-dev/web/packages/test-runner/demo/source-maps/bundled/src/index.js/0 | {
"file_path": "modernweb-dev/web/packages/test-runner/demo/source-maps/bundled/src/index.js",
"repo_id": "modernweb-dev",
"token_count": 23
} | 232 |
/* @web/test-runner snapshot v1 */
export const snapshots = {};
snapshots["snapshot-a"] =
`some snapshot A1`;
/* end snapshot snapshot-a */
snapshots["snapshot-b"] =
`some snapshot B1`;
/* end snapshot snapshot-b */
snapshots["snapshot-c"] =
`some snapshot C1`;
/* end snapshot snapshot-c */
| modernweb-dev/web/packages/test-runner/demo/test/__snapshots__/pass-snapshot-1.test.snap.js/0 | {
"file_path": "modernweb-dev/web/packages/test-runner/demo/test/__snapshots__/pass-snapshot-1.test.snap.js",
"repo_id": "modernweb-dev",
"token_count": 103
} | 233 |
window.location.reload();
it('x', async () => {
await new Promise(r => setTimeout(r, 1000));
});
| modernweb-dev/web/packages/test-runner/demo/test/fail-location-reload.test.js/0 | {
"file_path": "modernweb-dev/web/packages/test-runner/demo/test/fail-location-reload.test.js",
"repo_id": "modernweb-dev",
"token_count": 35
} | 234 |
export default {
name: 'group-c',
files: 'c.test.js',
};
| modernweb-dev/web/packages/test-runner/demo/test/groups/c.test.config.mjs/0 | {
"file_path": "modernweb-dev/web/packages/test-runner/demo/test/groups/c.test.config.mjs",
"repo_id": "modernweb-dev",
"token_count": 26
} | 235 |
import { compareSnapshot } from '@web/test-runner-commands';
it('can test snapshot A', async () => {
await compareSnapshot({ name: 'snapshot-a', content: 'some snapshot A2' });
});
it('can test snapshot B', async () => {
await compareSnapshot({ name: 'snapshot-b', content: 'some snapshot B2' });
});
it('can test... | modernweb-dev/web/packages/test-runner/demo/test/pass-snapshot-2.test.js/0 | {
"file_path": "modernweb-dev/web/packages/test-runner/demo/test/pass-snapshot-2.test.js",
"repo_id": "modernweb-dev",
"token_count": 136
} | 236 |
export {};
| modernweb-dev/web/packages/test-runner/demo/tsc/dist/test/fail-1.test.d.ts/0 | {
"file_path": "modernweb-dev/web/packages/test-runner/demo/tsc/dist/test/fail-1.test.d.ts",
"repo_id": "modernweb-dev",
"token_count": 4
} | 237 |
import './shared-a.js';
import './shared-b.js';
| modernweb-dev/web/packages/test-runner/demo/tsc/dist/test/pass-5.test.d.ts/0 | {
"file_path": "modernweb-dev/web/packages/test-runner/demo/tsc/dist/test/pass-5.test.d.ts",
"repo_id": "modernweb-dev",
"token_count": 20
} | 238 |
// this file is autogenerated with the generate-mjs-dts-entrypoints script
import cjsEntrypoint from './dist/index.js';
const {
chromeLauncher,
startTestRunner,
defaultReporter,
summaryReporter,
dotReporter,
formatError,
constants,
TestRunner,
TestRunnerCli,
BufferedLogger,
TestSessionManager,
... | modernweb-dev/web/packages/test-runner/index.mjs/0 | {
"file_path": "modernweb-dev/web/packages/test-runner/index.mjs",
"repo_id": "modernweb-dev",
"token_count": 237
} | 239 |
import {
TestRunnerCoreConfig,
TestSessionManager,
SESSION_STATUS,
TestCoverage,
CoverageConfig,
BrowserLauncher,
} from '@web/test-runner-core';
import { bold, gray, green, red } from 'nanocolors';
import { getPassedFailedSkippedCount } from './utils/getPassedFailedSkippedCount.js';
import { getCodeCovera... | modernweb-dev/web/packages/test-runner/src/reporter/getTestProgress.ts/0 | {
"file_path": "modernweb-dev/web/packages/test-runner/src/reporter/getTestProgress.ts",
"repo_id": "modernweb-dev",
"token_count": 2057
} | 240 |
// GENERATED by update-package-tsconfig
{
"files": [],
"references": [
{
"path": "./dev-server-core/tsconfig.json"
},
{
"path": "./test-runner-core/tsconfig.json"
},
{
"path": "./test-runner-coverage-v8/tsconfig.json"
},
{
"path": "./test-runner-server/tsconfig.js... | modernweb-dev/web/packages/tsconfig.project.json/0 | {
"file_path": "modernweb-dev/web/packages/tsconfig.project.json",
"repo_id": "modernweb-dev",
"token_count": 521
} | 241 |
const packages = [
{ name: 'config-loader', type: 'js', environment: 'node' },
{ name: 'parse5-utils', type: 'js', environment: 'node' },
{ name: 'browser-logs', type: 'ts', environment: 'node' },
{ name: 'polyfills-loader', type: 'ts', environment: 'node' },
{ name: 'rollup-plugin-html', type: 'ts', environm... | modernweb-dev/web/workspace-packages.mjs/0 | {
"file_path": "modernweb-dev/web/workspace-packages.mjs",
"repo_id": "modernweb-dev",
"token_count": 874
} | 242 |
const fs = require('fs');
const path = require('path');
const langsPath = path.resolve(__dirname, '../src/lang');
const oldLangsPath = path.resolve(__dirname, '../src/lang/old');
const excludedLangKeys = ['title_template'];
const langs = fs.readdirSync(langsPath).filter(dir => ['.', '..', 'old', 'index.js'].includes(... | odota/web/dev/migrateLangFormat.js/0 | {
"file_path": "odota/web/dev/migrateLangFormat.js",
"repo_id": "odota",
"token_count": 496
} | 243 |
<svg xmlns="http://www.w3.org/2000/svg" height="480" width="640" viewBox="0 0 640 480">
<defs>
<clipPath id="a">
<path fill-opacity=".67" d="M0 0h640v480H0z"/>
</clipPath>
</defs>
<g clip-path="url(#a)">
<path fill-rule="evenodd" fill="#fff" d="M.426.42H403.1v240.067H.427z"/>
<path d="M.426.... | odota/web/public/assets/images/flags/ai.svg/0 | {
"file_path": "odota/web/public/assets/images/flags/ai.svg",
"repo_id": "odota",
"token_count": 31917
} | 244 |
<svg xmlns="http://www.w3.org/2000/svg" height="480" width="640" viewBox="0 0 640 480">
<g fill-rule="evenodd">
<path fill="#de0000" d="M640.003 479.578H.378V0h639.625z"/>
<path fill="#35a100" d="M639.628 480H.003V240.216h639.625z"/>
<path fill="#fff300" d="M254.612 276.188l-106.066-72.434 131.043.122 40.... | odota/web/public/assets/images/flags/bf.svg/0 | {
"file_path": "odota/web/public/assets/images/flags/bf.svg",
"repo_id": "odota",
"token_count": 210
} | 245 |
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="480" width="640" viewBox="0 0 640 480">
<defs>
<path id="b" d="M0-1l.225.69H.95L.364.12l.225.69L0 .383-.588.81l.225-.692L-.95-.31h.725z"/>
<clipPath id="a">
<path fill-opacity=".67" d="M0 0h682.67v512H0z"/>
</... | odota/web/public/assets/images/flags/cw.svg/0 | {
"file_path": "odota/web/public/assets/images/flags/cw.svg",
"repo_id": "odota",
"token_count": 346
} | 246 |
<svg xmlns="http://www.w3.org/2000/svg" height="480" width="640" viewBox="0 0 640 480">
<g fill-rule="evenodd" stroke-width="1pt">
<path fill="#fff" d="M0 0h640v480H0z"/>
<path fill="#0039a6" d="M0 160.003h640V480H0z"/>
<path fill="#d52b1e" d="M0 319.997h640V480H0z"/>
</g>
</svg>
| odota/web/public/assets/images/flags/ru.svg/0 | {
"file_path": "odota/web/public/assets/images/flags/ru.svg",
"repo_id": "odota",
"token_count": 145
} | 247 |
<svg xmlns="http://www.w3.org/2000/svg" height="480" width="640" viewBox="0 0 640 480">
<path fill="#377e3f" d="M.1 0h640v480H.1z"/>
<path fill="#fff" d="M.1 96h640v288H.1z"/>
<path fill="#b40a2d" d="M.1 144h640v192H.1z"/>
<path d="M320 153.167l56.427 173.666-147.73-107.33h182.605l-147.73 107.33z" fill="#ecc81d... | odota/web/public/assets/images/flags/sr.svg/0 | {
"file_path": "odota/web/public/assets/images/flags/sr.svg",
"repo_id": "odota",
"token_count": 165
} | 248 |
<svg xmlns="http://www.w3.org/2000/svg" height="480" width="640" viewBox="0 0 640 480">
<defs>
<clipPath id="a">
<path fill-opacity=".67" d="M-85.333 0h682.67v512h-682.67z"/>
</clipPath>
</defs>
<g fill-rule="evenodd" clip-path="url(#a)" transform="translate(80) scale(.9375)">
<path fill="#e7001... | odota/web/public/assets/images/flags/tn.svg/0 | {
"file_path": "odota/web/public/assets/images/flags/tn.svg",
"repo_id": "odota",
"token_count": 499
} | 249 |
<svg xmlns="http://www.w3.org/2000/svg" height="480" width="640" viewBox="0 0 640 480">
<g fill-rule="evenodd">
<path fill="#f4f100" d="M0 0h640v480H0z"/>
<path fill="#199a00" d="M490 0h150v480H490z"/>
<path fill="#0058aa" d="M0 0h150v480H0z"/>
<path d="M259.26 129.95l-46.376 71.391 44.748 74.391 43.8... | odota/web/public/assets/images/flags/vc.svg/0 | {
"file_path": "odota/web/public/assets/images/flags/vc.svg",
"repo_id": "odota",
"token_count": 263
} | 250 |
import config from '../config';
const url = '/api/request';
const START = 'request/START';
const ERROR = 'request/ERROR';
const OK = 'request/OK';
const PROGRESS = 'request/PROGRESS';
export const requestActions = {
START,
ERROR,
OK,
PROGRESS,
};
const requestStart = () => ({
type: START,
});
const reque... | odota/web/src/actions/requestActions.js/0 | {
"file_path": "odota/web/src/actions/requestActions.js",
"repo_id": "odota",
"token_count": 626
} | 251 |
import React from 'react';
import styled from 'styled-components';
import ReactTooltip from 'react-tooltip';
import PropTypes from 'prop-types';
import constants from '../constants';
import AghanimsTooltipHeader from './AghsTooltipHeader';
import AghsTooltipBody from './AghsTooltipBody';
import config from '../../confi... | odota/web/src/components/AghsTooltip/index.jsx/0 | {
"file_path": "odota/web/src/components/AghsTooltip/index.jsx",
"repo_id": "odota",
"token_count": 1432
} | 252 |
import React from 'react';
import PropTypes from 'prop-types';
import styled from 'styled-components';
import Transition from 'react-transition-group/Transition';
import { connect } from 'react-redux';
import { IconPlusSquare, IconMinusSquare } from '../Icons';
import constants from '../constants';
const ButtonContain... | odota/web/src/components/Collapsible/index.jsx/0 | {
"file_path": "odota/web/src/components/Collapsible/index.jsx",
"repo_id": "odota",
"token_count": 1342
} | 253 |
import heroes from 'dotaconstants/build/heroes.json';
import store from '../../store';
// import fields from './fields';
const items = (await import('dotaconstants/build/items.json')).default;
const sqlfs = ['SELECT', 'WHERE', 'GROUP BY', 'ORDER BY'];
const sqlts = ['FROM', 'JOIN', 'LEFT JOIN'];
const tables = ['matc... | odota/web/src/components/Explorer/autocomplete.js/0 | {
"file_path": "odota/web/src/components/Explorer/autocomplete.js",
"repo_id": "odota",
"token_count": 946
} | 254 |
export { default } from './FourOhFour';
| odota/web/src/components/FourOhFour/index.js/0 | {
"file_path": "odota/web/src/components/FourOhFour/index.js",
"repo_id": "odota",
"token_count": 12
} | 255 |
import React from 'react';
import { connect } from 'react-redux';
import { shape, number, string, bool } from 'prop-types';
import styled from 'styled-components';
import constants from '../constants';
import Attribute from './Attribute';
import { compileLevelOneStats } from '../../utility';
const AttributesWrapper = ... | odota/web/src/components/Hero/AttributesBlock.jsx/0 | {
"file_path": "odota/web/src/components/Hero/AttributesBlock.jsx",
"repo_id": "odota",
"token_count": 1661
} | 256 |
import React from 'react';
import PropTypes from 'prop-types';
import Helmet from 'react-helmet';
import { connect } from 'react-redux';
import heroes from 'dotaconstants/build/heroes.json';
import { getHeroStats, getProPlayers } from '../../actions';
import Heading from '../Heading';
import Table from '../Table';
impo... | odota/web/src/components/Heroes/index.jsx/0 | {
"file_path": "odota/web/src/components/Heroes/index.jsx",
"repo_id": "odota",
"token_count": 2674
} | 257 |
import React from 'react';
import constants from '../constants';
export default props => (
<svg
{...props}
viewBox="0 0 300 300"
style={{
fill: 'none',
stroke: constants.textColorPrimary,
strokeWidth: 10,
}}
>
<path
d="M141.4,234.6c0,0,17.4-7.3,39-10s38.7,0.7,38.7,0.7"
... | odota/web/src/components/Icons/Cheese.jsx/0 | {
"file_path": "odota/web/src/components/Icons/Cheese.jsx",
"repo_id": "odota",
"token_count": 1183
} | 258 |
import React from 'react';
export default props => (
<svg {...props} viewBox="0 0 300 300">
<path
d="M149.9,237.2c11.5,0,8.3,21.6,16.6,21.6s29.8-68.3,9.1-70.7c-20.8-2.4-12.1,24-25.7,24V237.2z"
/>
<path
d="M149.9,103.2c2.2,0,8,11.5,22.1,18.2c10,4.7,24.9,8.1,33.6,13.7c21,13.5-0.9,50-4.5,49.1c-3... | odota/web/src/components/Icons/Roshan.jsx/0 | {
"file_path": "odota/web/src/components/Icons/Roshan.jsx",
"repo_id": "odota",
"token_count": 1060
} | 259 |
import React, { createElement } from 'react';
import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import { Link } from 'react-router-dom';
import AvVolumeUp from 'material-ui/svg-icons/av/volume-up';
import Checkbox from 'material-ui/Checkbox';
import Visibility from 'material-ui/svg-icons/action... | odota/web/src/components/Match/Chat/Chat.jsx/0 | {
"file_path": "odota/web/src/components/Match/Chat/Chat.jsx",
"repo_id": "odota",
"token_count": 8625
} | 260 |
import React from 'react';
import { connect } from 'react-redux';
import { string, oneOfType, number, bool, shape } from 'prop-types';
import playerColors from 'dotaconstants/build/player_colors.json';
import heroes from 'dotaconstants/build/heroes.json';
import styled from 'styled-components';
import constants from '.... | odota/web/src/components/Match/PlayerThumb/index.jsx/0 | {
"file_path": "odota/web/src/components/Match/PlayerThumb/index.jsx",
"repo_id": "odota",
"token_count": 550
} | 261 |
import heroData from 'dotaconstants/build/heroes.json';
import gameModeData from 'dotaconstants/build/game_mode.json';
import lobbyTypeData from 'dotaconstants/build/lobby_type.json';
// import patchData from 'dotaconstants/build/patch.json';
import store from '../../store';
import { formatTemplateToString } from '../.... | odota/web/src/components/Meta/fields.js/0 | {
"file_path": "odota/web/src/components/Meta/fields.js",
"repo_id": "odota",
"token_count": 1850
} | 262 |
import styled from 'styled-components';
import constants from '../../../constants';
export const Styled = styled.div`
position: relative;
text-align: center;
padding: 10px;
.tt-container {
white-space: nowrap;
text-align: center;
}
.result {
font-size: 16px;
font-weight: bold;
}
.win... | odota/web/src/components/Player/Pages/Activity/Styled.jsx/0 | {
"file_path": "odota/web/src/components/Player/Pages/Activity/Styled.jsx",
"repo_id": "odota",
"token_count": 1083
} | 263 |
import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { getPlayerPros } from '../../../../actions';
import Table from '../../../Table';
import Container from '../../../Container';
import playerProsColumns from './playerProsColumns';
const Pros = ({
data, playerI... | odota/web/src/components/Player/Pages/Pros/Pros.jsx/0 | {
"file_path": "odota/web/src/components/Player/Pages/Pros/Pros.jsx",
"repo_id": "odota",
"token_count": 569
} | 264 |
export { default } from './Player';
export { default as AppBadge } from './Header/AppBadge';
| odota/web/src/components/Player/index.js/0 | {
"file_path": "odota/web/src/components/Player/index.js",
"repo_id": "odota",
"token_count": 28
} | 265 |
import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import heroes from 'dotaconstants/build/heroes.json';
import {
transformations,
fromNow,
subTextStyle,
} from '../../utility';
import Table, { TableLink } from '../Table';
import Container from '../Container';
//... | odota/web/src/components/Search/SearchResult.jsx/0 | {
"file_path": "odota/web/src/components/Search/SearchResult.jsx",
"repo_id": "odota",
"token_count": 1547
} | 266 |
import Status from './Status';
export default Status;
| odota/web/src/components/Status/index.js/0 | {
"file_path": "odota/web/src/components/Status/index.js",
"repo_id": "odota",
"token_count": 14
} | 267 |
import React from 'react';
import styled from 'styled-components';
import propTypes from 'prop-types';
import ReactTooltip from 'react-tooltip';
import LevelGroup from './LevelGroup';
const Wrapper = styled.div`
.__react_component_tooltip {
opacity: 1 !important;
padding: 0px !important;
}
`;
const Content =... | odota/web/src/components/TalentsTooltip/index.jsx/0 | {
"file_path": "odota/web/src/components/TalentsTooltip/index.jsx",
"repo_id": "odota",
"token_count": 517
} | 268 |
import styled from 'styled-components';
import constants from '../../constants';
export const StyledTooltip = styled.div`
position: relative;
width:auto;
display: block;
padding: 0.5em;
background-color: ${constants.darkPrimaryColor};
`;
export const StyledTooltipTeam = styled.span`
position: relative;
... | odota/web/src/components/Visualizations/Graph/Styled.jsx/0 | {
"file_path": "odota/web/src/components/Visualizations/Graph/Styled.jsx",
"repo_id": "odota",
"token_count": 552
} | 269 |
import { useSelector } from 'react-redux';
export const useStrings = () => {
const strings = useSelector((state) => state.app.strings);
return strings;
};
export default useStrings;
| odota/web/src/hooks/useStrings.hook.js/0 | {
"file_path": "odota/web/src/hooks/useStrings.hook.js",
"repo_id": "odota",
"token_count": 58
} | 270 |
{
"yes": "si",
"no": "no",
"abbr_thousand": "k",
"abbr_million": "m",
"abbr_billion": "b",
"abbr_trillion": "t",
"abbr_quadrillion": "q",
"abbr_not_available": "Non disponibile",
"abbr_pick": "P",
"abbr_win": "W",
"abbr_number": "N.",
"analysis_eff": "Efficienza in lane",
"analysis_farm_drough... | odota/web/src/lang/it-IT.json/0 | {
"file_path": "odota/web/src/lang/it-IT.json",
"repo_id": "odota",
"token_count": 19932
} | 271 |
{
"yes": "так",
"no": "ні",
"abbr_thousand": "тис",
"abbr_million": "міл",
"abbr_billion": "м",
"abbr_trillion": "т",
"abbr_quadrillion": "к",
"abbr_not_available": "Н/Д",
"abbr_pick": "В",
"abbr_win": "П",
"abbr_number": "Ні.",
"analysis_eff": "Ефективність на лінії",
"analysis_farm_drought":... | odota/web/src/lang/uk-UA.json/0 | {
"file_path": "odota/web/src/lang/uk-UA.json",
"repo_id": "odota",
"token_count": 30175
} | 272 |
{
"command": "SELECT",
"rowCount": 116,
"oid": null,
"rows": [
{
"hero_id": 14,
"games": 44316,
"pickrate": 0.438390313390313,
"winrate": 0.522362126545717
},
{
"hero_id": 74,
"games": 27551,
"pickrate": 0.272544713516936,
"winrate": 0.493085550433741
},
{
"hero_id": 67,
"gam... | odota/web/testcafe/cachedAjax/explorer_sql=%0Aselect%20hero_id%20%2C%20%0Ac.json/0 | {
"file_path": "odota/web/testcafe/cachedAjax/explorer_sql=%0Aselect%20hero_id%20%2C%20%0Ac.json",
"repo_id": "odota",
"token_count": 7766
} | 273 |
[
{
"match_id": "4096961695",
"start_time": "1535907490",
"hero_id": "",
"score": "10597"
},
{
"match_id": "4110934266",
"start_time": "1536589185",
"hero_id": "",
"score": "9682"
},
{
"match_id": "4097603620",
"start_time": "1535950875",
"hero_id": "",
"score": "9552"
},
{
"match_id": ... | odota/web/testcafe/cachedAjax/records_duration_.json/0 | {
"file_path": "odota/web/testcafe/cachedAjax/records_duration_.json",
"repo_id": "odota",
"token_count": 5474
} | 274 |
package pawndex
import (
"bytes"
"context"
"encoding/json"
"fmt"
"io/ioutil"
"net/http"
"path/filepath"
"strings"
"time"
"github.com/Southclaws/sampctl/pawnpackage"
"github.com/Southclaws/sampctl/versioning"
"github.com/google/go-github/github"
"github.com/pkg/errors"
"go.uber.org/zap"
"gopkg.in/yaml.v... | openmultiplayer/web/app/resources/pawndex/scraper.go/0 | {
"file_path": "openmultiplayer/web/app/resources/pawndex/scraper.go",
"repo_id": "openmultiplayer",
"token_count": 1767
} | 275 |
package authentication
import (
"context"
"fmt"
"time"
"github.com/google/go-github/v28/github"
"github.com/patrickmn/go-cache"
"github.com/pkg/errors"
"github.com/thanhpk/randstr"
"golang.org/x/oauth2"
githuboa "golang.org/x/oauth2/github"
"github.com/openmultiplayer/web/app/resources/user"
"github.com/o... | openmultiplayer/web/app/services/authentication/github.go/0 | {
"file_path": "openmultiplayer/web/app/services/authentication/github.go",
"repo_id": "openmultiplayer",
"token_count": 1237
} | 276 |
package github
import (
"net/http"
"github.com/go-chi/chi"
"github.com/pkg/errors"
"github.com/openmultiplayer/web/app/services/authentication"
"github.com/openmultiplayer/web/internal/web"
)
type service struct {
auth *authentication.State
oa2 *authentication.GitHubProvider
}
func New(auth *authentication... | openmultiplayer/web/app/transports/api/auth/github/api.go/0 | {
"file_path": "openmultiplayer/web/app/transports/api/auth/github/api.go",
"repo_id": "openmultiplayer",
"token_count": 479
} | 277 |
package servers
import (
"net/http"
"github.com/go-chi/chi"
"github.com/pkg/errors"
"github.com/openmultiplayer/web/internal/db"
"github.com/openmultiplayer/web/internal/web"
)
func (s *service) get(w http.ResponseWriter, r *http.Request) {
// This used to be for getting servers from database directly
// res... | openmultiplayer/web/app/transports/api/servers/h_get.go/0 | {
"file_path": "openmultiplayer/web/app/transports/api/servers/h_get.go",
"repo_id": "openmultiplayer",
"token_count": 310
} | 278 |
---
title: Changelog
description: open.mp development progress and changelog.
---
## **[v1.2.0.2670](https://github.com/openmultiplayer/open.mp/releases/tag/v1.2.0.2670) (Latest)**
We encourage every open.mp server to update to this version. There has been not only noticeable performance improvements, but also **crit... | openmultiplayer/web/docs/changelog.md/0 | {
"file_path": "openmultiplayer/web/docs/changelog.md",
"repo_id": "openmultiplayer",
"token_count": 6842
} | 279 |
---
title: OnGameModeExit
description: This callback is called when a gamemode ends, either through 'gmx', the server being shut down, or GameModeExit.
tags: []
---
## Description
This callback is called when a gamemode ends, either through 'gmx', the server being shut down, or GameModeExit.
## Examples
```c
public... | openmultiplayer/web/docs/scripting/callbacks/OnGameModeExit.md/0 | {
"file_path": "openmultiplayer/web/docs/scripting/callbacks/OnGameModeExit.md",
"repo_id": "openmultiplayer",
"token_count": 456
} | 280 |
---
title: OnPlayerClickPlayerGangZone
description: This callback is called when a player clicked a player gangzone on the pause menu map (by right-clicking).
tags: ["player", "gangzone"]
---
<VersionWarn version='omp v1.1.0.2612' />
## Description
This callback is called when a player clicked a player gangzone on t... | openmultiplayer/web/docs/scripting/callbacks/OnPlayerClickPlayerGangZone.md/0 | {
"file_path": "openmultiplayer/web/docs/scripting/callbacks/OnPlayerClickPlayerGangZone.md",
"repo_id": "openmultiplayer",
"token_count": 490
} | 281 |
---
title: OnPlayerFinishedDownloading
description: This callback is called when a player finishes downloading custom models.
tags: ["player"]
---
<VersionWarn name='callback' version='SA-MP 0.3.DL R1' />
## Description
This callback is called when a player finishes downloading custom models. For more information on... | openmultiplayer/web/docs/scripting/callbacks/OnPlayerFinishedDownloading.md/0 | {
"file_path": "openmultiplayer/web/docs/scripting/callbacks/OnPlayerFinishedDownloading.md",
"repo_id": "openmultiplayer",
"token_count": 511
} | 282 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.