mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
Merge remote-tracking branch 'origin/release-3.0' into async-accounts-base
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
title: Meteor API Docs
|
||||
subtitle: API Docs
|
||||
versions:
|
||||
- '2.9'
|
||||
- '2.8'
|
||||
- '2.7'
|
||||
- '2.6'
|
||||
|
||||
@@ -31,8 +31,18 @@
|
||||
by [henriquealbert](https://github.com/henriquealbert).
|
||||
|
||||
#### Breaking Changes
|
||||
N/A
|
||||
|
||||
* Most of OAuth related code has been moved from `accounts-base` to `accounts-oauth`.
|
||||
#### Internal API changes
|
||||
* Internal methods from `OAuth` that are now async:
|
||||
- _attemptLogin
|
||||
- _loginMethod
|
||||
- _runLoginHandlers
|
||||
- OAuth.registerService now accepts async functions
|
||||
|
||||
OAuth related code has been moved from `accounts-base` to `accounts-oauth`, removing the dependency on `service-configuration`
|
||||
more can be seen in this [discussion](https://github.com/meteor/meteor/discussions/12171) and in the [PR](https://github.com/meteor/meteor/pull/12202).
|
||||
This means that if you don’t use third-party login on your project, you don’t need to add the package service-configuration anymore.
|
||||
|
||||
#### Migration Steps
|
||||
|
||||
|
||||
2
meteor
2
meteor
@@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
BUNDLE_VERSION=14.21.1.4
|
||||
BUNDLE_VERSION=14.21.1.7
|
||||
|
||||
# OS Check. Put here because here is where we download the precompiled
|
||||
# bundles that are arch specific.
|
||||
|
||||
@@ -185,14 +185,16 @@ function getDefaultsForNode8(features) {
|
||||
|
||||
// Ensure that async functions run in a Fiber, while also taking
|
||||
// full advantage of native async/await support in Node 8.
|
||||
const isFiberDisabled = process.env.DISABLE_FIBERS === '1';
|
||||
const ignoreAsyncPlugin = process.env.IGNORE_ASYNC_PLUGIN === '1';
|
||||
|
||||
combined.plugins.push([require("./plugins/async-await.js"), {
|
||||
// Do not transform `await x` to `Promise.await(x)`, since Node
|
||||
// 8 has native support for await expressions.
|
||||
useNativeAsyncAwait: !process.env.DISABLE_FIBERS,
|
||||
isFiberDisabled: process.env.DISABLE_FIBERS,
|
||||
}]);
|
||||
|
||||
if (!ignoreAsyncPlugin) {
|
||||
combined.plugins.push([require("./plugins/async-await.js"), {
|
||||
// Do not transform `await x` to `Promise.await(x)`, since Node
|
||||
// 8 has native support for await expressions.
|
||||
useNativeAsyncAwait: isFiberDisabled,
|
||||
}]);
|
||||
}
|
||||
// Enable async generator functions proposal.
|
||||
combined.plugins.push(require("@babel/plugin-proposal-async-generator-functions"));
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "@meteorjs/babel",
|
||||
"author": "Meteor <dev@meteor.com>",
|
||||
"version": "7.18.0-beta.1",
|
||||
"version": "7.18.0-beta.4",
|
||||
"license": "MIT",
|
||||
"description": "Babel wrapper package for use with Meteor",
|
||||
"keywords": [
|
||||
|
||||
@@ -9,7 +9,7 @@ module.exports = function (babel) {
|
||||
Function: {
|
||||
exit: function (path) {
|
||||
const node = path.node;
|
||||
if (!node.async || !this.opts.isFiberDisabled) {
|
||||
if (!node.async) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -166,8 +166,8 @@ Tinytest.addAsync('livedata server - async publish cursor', function(
|
||||
const remoteCollection = new Mongo.Collection('names', {
|
||||
connection: clientConn,
|
||||
});
|
||||
clientConn.subscribe('asyncPublishCursor', () => {
|
||||
const actual = remoteCollection.find().fetch();
|
||||
clientConn.subscribe('asyncPublishCursor', async () => {
|
||||
const actual = await remoteCollection.find().fetch();
|
||||
test.equal(actual[0].name, 'async');
|
||||
onComplete();
|
||||
});
|
||||
|
||||
@@ -15,7 +15,7 @@ var packageJson = {
|
||||
"node-gyp": "8.0.0",
|
||||
"node-pre-gyp": "0.15.0",
|
||||
typescript: "4.5.4",
|
||||
"@meteorjs/babel": "7.18.0-beta.1",
|
||||
"@meteorjs/babel": "7.18.0-beta.4",
|
||||
// Keep the versions of these packages consistent with the versions
|
||||
// found in dev-bundle-server-package.js.
|
||||
"meteor-promise": "0.9.0",
|
||||
|
||||
Reference in New Issue
Block a user